Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-4595

QDomDocument::toString() asserts when called on document which specifies an unknown encoding

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P1: Critical
    • 4.6.0
    • 4.5.2
    • XML: DOM
    • None
    • 40909863e9eb17e0d0469ade608426dbbd08b43e

    Description

      QDomDocument::toString() asserts when called on a document which specifies an unknown encoding.

      The following example reproduces the assertion:

      QString xml("<?xml version='1.0' encoding='unknown-encoding'?>"
      "<foo>"
      " <bar>How will this sentence be handled?</bar>"
      "</foo>");

      QDomDocument d;
      d.setContent(xml);

      QString string = d.toString(); // causes assertion

      Autotest added: 3e23d922c6547f7295c425b28a9c9fc0791dbfa5

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            phartman Peter Hartmann (closed Nokia identity) (Inactive)
            sthomass Stian Sandvik Thomassen (closed Nokia identity) (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes