[Interest] XML schema validation alternatives?

Constantin Makshin cmakshin at gmail.com
Tue May 12 07:29:06 CEST 2015


libxml (http://xmlsoft.org/, MIT license) is a relatively popular
library which supports both DTD
(http://xmlsoft.org/html/libxml-valid.html) and schema
(http://xmlsoft.org/html/libxml-xmlschemas.html#xmlSchemaNewValidCtxt)
validation.

On 05/11/2015 10:49 PM, Murphy, Sean wrote:
> 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.
> 
> Sean

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20150512/56204713/attachment.sig>


More information about the Interest mailing list