[JAXP-69] Double-checked locking bug in javax.xml.parsers.FactoryFinder.find(String, String) Created: 03/Jun/11  Updated: 11/Jul/11  Resolved: 11/Jul/11

Status: Resolved
Project: jaxp
Component/s: None
Affects Version/s: current
Fix Version/s: jaxp.next

Type: Bug Priority: Minor
Reporter: ryanhos Assignee: Joe Wang
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


javax.xml.parsers.FactoryFinder.find(String, String), revision 3037 contains a double checked locking bug.

The simple solution is to make static boolean field "firstTime" volatile and move the assignment "firstTime = false;" after the call to "cacheProps.load(ss.getFileInputStream(f));"

I did search for this bug, but can never seem to get good information out of JIRA's search feature. Please excuse me if I have submitted a duplicate.

Comment by Joe Wang [ 11/Jul/11 ]

Patch is now in the source repository. It will be integrated into an update release of jdk7 together with other fixes.

Thanks for your contribution!

Generated at Tue Feb 21 00:38:49 UTC 2017 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.