You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2007/02/23 05:09:47 UTC

svn commit: r510801 - /tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/loader/WebappClassLoader.java

Author: markt
Date: Thu Feb 22 20:09:46 2007
New Revision: 510801

URL: http://svn.apache.org/viewvc?view=rev&rev=510801
Log:
Port Remy's CL deadlock quick fix from TC6

Modified:
    tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/loader/WebappClassLoader.java

Modified: tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/loader/WebappClassLoader.java
URL: http://svn.apache.org/viewvc/tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/loader/WebappClassLoader.java?view=diff&rev=510801&r1=510800&r2=510801
==============================================================================
--- tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/loader/WebappClassLoader.java (original)
+++ tomcat/container/tc5.5.x/catalina/src/share/org/apache/catalina/loader/WebappClassLoader.java Thu Feb 22 20:09:46 2007
@@ -1796,7 +1796,7 @@
         if (clazz != null)
             return clazz;
 
-        synchronized (entry) {
+        synchronized (this) {
             if (entry.binaryContent == null && entry.loadedClass == null)
                 throw new ClassNotFoundException(name);
 
@@ -1810,18 +1810,16 @@
     
             if (packageName != null) {
 
-                synchronized(this) {
-                    pkg = getPackage(packageName);
-        
-                    // Define the package (if null)
-                    if (pkg == null) {
-                        if (entry.manifest == null) {
-                            definePackage(packageName, null, null, null, null,
-                                    null, null, null);
-                        } else {
-                            definePackage(packageName, entry.manifest,
-                                    entry.codeBase);
-                        }
+                pkg = getPackage(packageName);
+    
+                // Define the package (if null)
+                if (pkg == null) {
+                    if (entry.manifest == null) {
+                        definePackage(packageName, null, null, null, null,
+                                null, null, null);
+                    } else {
+                        definePackage(packageName, entry.manifest,
+                                entry.codeBase);
                     }
                 }
             }



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org