2015-05-11 21:49 GMT+02:00 Murphy, Sean <smur...@walbro.com>: > I was trying to use QXmlSchemaValidator to validate XML files vs. their > associated schema and I'm encountering an infinite loop that eventually > causes the application to crash. It's been reported (over 5 years ago) in > https://bugreports.qt.io/browse/QTBUG-12534 It fails on pretty simple > examples, when the schema contains an "xs:all", another bug reporting it > that has a very simple schema/xml example is > https://bugreports.qt.io/browse/QTBUG-35052 . > > Does anyone have a recommended alternative? Either a workaround to still > use this class, or a third party library (preferable LGPL or similar > licensing) that I could use for XML validation? One pretty hacky workaround > is that changing the xs:all to an xs:sequence in the schema document fixes > the issue, except that imposes an unwanted restriction in the corresponding > XML files that the elements need to come in a specific order, which isn't > really what we want. >
No idea if there's a workaround (that's an old bug!). I've used libxml2 and Xerces in the past. Btw, Fredrik recently posted to the list about the issues with the unmaintained QtXmlPatterns module [1]. You might want to let him know about your use case. Cheers, Elvis [1] http://lists.qt-project.org/pipermail/interest/2015-May/016714.html > > Sean > _______________________________________________ > Interest mailing list > Interest@qt-project.org > http://lists.qt-project.org/mailman/listinfo/interest >
_______________________________________________ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest