diff options
author | Ulf Hermann <ulf.hermann@qt.io> | 2017-09-12 17:31:31 +0200 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@qt.io> | 2017-09-13 07:29:00 +0000 |
commit | 3b5b8f1d4ab8092e5dd337b7b4e32d85fda2e0b7 (patch) | |
tree | 0c3d8e427eeeb440e4e20a836f9e1721d72e10a7 /src/plugins/platforms/ios/quiview.mm | |
parent | 71a2dd955cdc15317c83ad35b4845ef864cba0ef (diff) |
QXmlStreamWriter: Avoid writing invalid characters
Some valid UTF-16 characters cannot be expressed in XML 1.0 and a
QString may contain invalid unicode. In both cases we should not write
the respective data to the output stream, as that generates invalid XML,
which then cannot be read back by QXmlStreamReader. In addition we
should report an error if we encounter them.
The change filters the incorrect strings from the output and introduces
an "encodingError" flag which is reported from hasError().
[ChangeLog][Important Behavior Changes] Characters invalid in XML, such
as 0x0 or 0xfffe, as well as strings containing unmatched UTF-16
surrogates are now suppressed from the output of QXmlStreamWriter and
cause the error flag to be set.
Task-number: QTBUG-63150
Change-Id: Ia29bab768fed9681dd68e8934da2a7e3fcdfc3cd
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/plugins/platforms/ios/quiview.mm')
0 files changed, 0 insertions, 0 deletions