Improve exception processing in CustomObjectInputStream#resolveClass(),
to help find the cause behind BZ 48007.
git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@920912
13f79535-47bb-0310-9956-
ffa450edef68
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;
+ }
}
}