RFR (JAXP) 6770436 : Entity callback order differs between Java1.5 and Java1.6

huizhe wang huizhe.wang at oracle.com
Mon Nov 3 21:09:41 UTC 2014


Hi,

The order of the Character event for a built-in entity reference was 
wrong after the integration of StAX in JDK 6. The error was introduced 
when all Character event was moved to the scanDocument method. The 
Character event in handleCharacter method was then commented out to 
avoid duplicate Character event. However, that change also changed the 
event sequence, startEntity - characters - endEntity became startEntity 
- endEntity - characters.

The following fix adds a flag builtInRefCharacterHandled to indicate 
whether or not the Character event has been handled. If yes, an 
ENTITY_REFERENCE is returned, which does nothing.

http://cr.openjdk.java.net/~joehw/jdk9/6770436/webrev/

Please review.

Thanks,
Joe



More information about the core-libs-dev mailing list