You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by kk...@apache.org on 2010/03/09 16:04:53 UTC

svn commit: r920912 - /tomcat/trunk/java/org/apache/catalina/util/CustomObjectInputStream.java

Author: kkolinko
Date: Tue Mar  9 15:04:53 2010
New Revision: 920912

URL: http://svn.apache.org/viewvc?rev=920912&view=rev
Log:
https://issues.apache.org/bugzilla/show_bug.cgi?id=48007#c5
Improve exception processing in CustomObjectInputStream#resolveClass(),
to help find the cause behind BZ 48007.

Modified:
    tomcat/trunk/java/org/apache/catalina/util/CustomObjectInputStream.java

Modified: tomcat/trunk/java/org/apache/catalina/util/CustomObjectInputStream.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/util/CustomObjectInputStream.java?rev=920912&r1=920911&r2=920912&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/catalina/util/CustomObjectInputStream.java (original)
+++ tomcat/trunk/java/org/apache/catalina/util/CustomObjectInputStream.java Tue Mar  9 15:04:53 2010
@@ -75,8 +75,14 @@ public final class CustomObjectInputStre
         try {
             return Class.forName(classDesc.getName(), false, classLoader);
         } catch (ClassNotFoundException e) {
-            // Try also the superclass because of primitive types
-            return super.resolveClass(classDesc);
+            try {
+                // Try also the superclass because of primitive types
+                return super.resolveClass(classDesc);
+            } catch (ClassNotFoundException e2) {
+                // Rethrow original exception, as it can have more information
+                // about why the class was not found. BZ 48007
+                throw e;
+            }
         }
     }
 



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