aboutsummaryrefslogtreecommitdiffstats
path: root/plugin/icedteanp/java
diff options
context:
space:
mode:
authorAdam Domurad <[email protected]>2013-02-07 14:18:24 -0500
committerAdam Domurad <[email protected]>2013-02-07 14:18:24 -0500
commit6e946f8c5fd09a843a76cdb24f5dc6ccbf9c36b4 (patch)
treeae9b0608984704cef41e0d4587ddb57b7a77657d /plugin/icedteanp/java
parentab80a9d3760309ffd0c84870a3ea9ee8548d847f (diff)
Only destroy full initialized applets
Diffstat (limited to 'plugin/icedteanp/java')
-rw-r--r--plugin/icedteanp/java/sun/applet/PluginAppletViewer.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java b/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java
index ac818d5..8a4f078 100644
--- a/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java
+++ b/plugin/icedteanp/java/sun/applet/PluginAppletViewer.java
@@ -587,6 +587,10 @@ public class PluginAppletViewer extends XEmbeddedFrame
private static synchronized void destroyApplet(int identifier) {
+ // We should not try to destroy an applet during
+ // initialization. It may cause an inconsistent state.
+ waitForAppletInit( applets.get(identifier).panel );
+
PluginDebug.debug("DestroyApplet called for ", identifier);
PAV_INIT_STATUS prev = updateStatus(identifier, PAV_INIT_STATUS.DESTROYED);