Mercurial > hg > release > icedtea6-1.4
changeset 1330:15437352b69c
- Fix bug that caused applet to crash if an optional class was not found
(happened due to a CFE being thrown when a site sends redirected page
content instead of 404 upon a class request). RH BZ: 477351
author | Deepak Bhole <dbhole@redhat.com> |
---|---|
date | Thu, 22 Jan 2009 13:36:49 -0500 |
parents | 0507a324ec22 |
children | c29bbfa41f2b |
files | ChangeLog plugin/icedtea/sun/applet/PluginAppletSecurityContext.java rt/net/sourceforge/jnlp/runtime/JNLPClassLoader.java |
diffstat | 3 files changed, 11 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog Thu Jan 22 17:55:26 2009 +0000 +++ b/ChangeLog Thu Jan 22 13:36:49 2009 -0500 @@ -1,3 +1,11 @@ +2009-01-22 Deepak Bhole <dbhole@redhat.com> + + * plugin/icedtea/sun/applet/PluginAppletSecurityContext.java: Use + Hashtable to store classloaders, instead of HashMap (values cannot be + null in HashTable). + * rt/net/sourceforge/jnlp/runtime/JNLPClassLoader.java: Catch CFE in + addition to CNFE. + 2009-01-22 Andrew Haley <aph@redhat.com> * ports/hotspot/src/cpu/zero/vm/stack_zero.hpp (class
--- a/plugin/icedtea/sun/applet/PluginAppletSecurityContext.java Thu Jan 22 17:55:26 2009 +0000 +++ b/plugin/icedtea/sun/applet/PluginAppletSecurityContext.java Thu Jan 22 13:36:49 2009 -0500 @@ -55,6 +55,7 @@ import java.security.ProtectionDomain; import java.util.ArrayList; import java.util.HashMap; +import java.util.Hashtable; import java.util.List; import net.sourceforge.jnlp.runtime.JNLPRuntime; @@ -224,7 +225,7 @@ public class PluginAppletSecurityContext { - public static HashMap<ClassLoader, String> classLoaders = new HashMap<ClassLoader, String>(); + public static Hashtable<ClassLoader, String> classLoaders = new Hashtable<ClassLoader, String>(); // FIXME: make private public PluginObjectStore store = new PluginObjectStore();
--- a/rt/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Thu Jan 22 17:55:26 2009 +0000 +++ b/rt/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Thu Jan 22 13:36:49 2009 -0500 @@ -775,6 +775,7 @@ return loaders[i].findClass(name); } catch(ClassNotFoundException ex) { } + catch(ClassFormatError cfe) {} } throw new ClassNotFoundException(name);