stevedlawrence opened a new pull request, #1501:
URL: https://github.com/apache/daffodil/pull/1501

   When the XMLTextInfosetInputter hits an error, it uses an XMLEventAllocator 
to create an event that we can get the current location from. However, if 
trailing data exists after the infoset then creating this event will fail with 
a null pointer exception. This does not appear to be a bug in woodstox, but is 
really just incorrect usage of the API.
   
   Fortunately, the XMLStreamReader already provides a getLocation function to 
get the current parse location. This is the preferred mechanism for this, so 
all instances of the allocator are replaced with the getLocation function. This 
also improves the error messages since getLocation provides column information 
in addition to line numbers, which could be useful for non-pretty printed 
infosets that are on a single line.
   
   In cases where the error comes from an XMLStreamException, we don't need to 
get location information at all since Woodstox already includes it in the 
exception message.
   
   DAFFODIL-3003


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@daffodil.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to