tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject DO NOT REPLY [Bug 37458] Datarace on org.apache.catalina.loader.WebappClassLoader
Date Fri, 02 Jan 2009 02:44:07 GMT

--- Comment #9 from Konstantin Kolinko <>  2009-01-01 18:44:06
PST ---
Created an attachment (id=23066)
 --> (
patch for WebappClassLoader class of tc6.0.x

I think the issue is caused by missing (entry.loadedClass == null) inside the
synchronized block. (Remember the double-checked locking pattern?)

I also wonder if there is a cause for (entry.loadedClass == null) check later
in the synchronized block (line 1845, i.e. before calling defineClass()) other
than this very bug.

Thus the patch. It is against tc6.0.x

I do not remember whether pointer assignments are atomic in current Java, and
thus whether it is safe to test for (entry.loadedClass) elsewhere in the code.

Configure bugmail:
------- You are receiving this mail because: -------
You are the assignee for the bug.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message