You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Xpp3DomBuilder.createXmlReader() system property race condition #392
Xpp3DomBuilder.createXmlReader() (lines 119-129) clears and restores the global org.xml.sax.driver system property without synchronization. In a multi-threaded environment (like Maven parallel builds), one thread's clear/restore sequence can interfere with another thread's read or write of the same property. The code even acknowledges this with the comment: "There's a 'slight' problem with this an parallel maven: It does not work ;)"
The method already tries to directly instantiate com.sun.org.apache.xerces.internal.parsers.SAXParser first (line 114), which succeeds on all Oracle/OpenJDK JVMs. The system property manipulation fallback is both unnecessary and harmful.
Fix: remove the system property manipulation. If the direct instantiation fails, just call XMLReaderFactory.createXMLReader() without modifying any system properties.
Activity