[serializer] fixed whitespace issue when decoding xml
bug #11054 [Serializer] Xml encoder whitespace fix (fieg)

This PR was merged into the 2.5 branch.

Discussion
----------

[Serializer] Xml encoder whitespace fix

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Hi, after #11044 I'm back with more: A fix for another BC-break issue regarding decoding xml since PR #10668.

The problem is that I was getting more `#cdata-section` keys in deeper levels of the decoded xml:

```php
  'str' =>
      array(2) {
        '#text' =>
        array(2) {
          ...
        }
        '#cdata-section' =>
        string(228) "Some text"
      }
```

//cc @csarrazi

Commits
-------

466a3d7 [serializer] fixed whitespace issue when decoding xml