Project

Profile

Help

Bug #2722

xml-to-json() does not reject an ill-formed document

Added by Michael Kay almost 4 years ago. Updated almost 3 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
XPath conformance
Sprint/Milestone:
Start date:
2016-04-21
Due date:
% Done:

100%

Legacy ID:
Applies to branch:
9.7, trunk
Fix Committed on Branch:
9.7, trunk
Fixed in Maintenance Release:

Description

If the input to xml-to-json() is a document node, the spec requires it to be well-formed in the sense that it has exactly one element child and no text node children. Saxon is not checking for this condition (new test case xml-to-json-C001).

History

#1 Updated by Michael Kay almost 4 years ago

  • Status changed from New to Resolved
  • Applies to branch 9.8 added
  • Fix Committed on Branch 9.7, 9.8 added

Fixed on the 9.7 and 9.8 branches. The fix reuses the existing DocumentValidator class which checks a document node for well-formedness; because xml-to-json() is in Saxon-HE, the DocumentValidator is moved from its current location to net.sf.saxon.event.

#2 Updated by O'Neil Delpratt almost 4 years ago

  • Status changed from Resolved to Closed
  • % Done changed from 0 to 100
  • Fixed in Maintenance Release 9.7.0.5 added

Bug fix applied in the Saxon 9.7.0.5 maintenance release.

#3 Updated by O'Neil Delpratt almost 4 years ago

  • Sprint/Milestone set to 9.7.0.5

#4 Updated by O'Neil Delpratt almost 3 years ago

  • Applies to branch trunk added
  • Applies to branch deleted (9.8)

#5 Updated by O'Neil Delpratt almost 3 years ago

  • Fix Committed on Branch trunk added
  • Fix Committed on Branch deleted (9.8)

Please register to edit this issue

Also available in: Atom PDF