Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUwe Stieber2012-02-23 02:27:05 -0500
committerUwe Stieber2012-02-23 02:27:48 -0500
commit005675c5f5cf51818e997d23320994cb3b523577 (patch)
treea3307424f4afe4b17bf4f846fe58a29409899b13
parent00619466ecda919b32c127dd80ba9944266c9c42 (diff)
downloadorg.eclipse.tcf-005675c5f5cf51818e997d23320994cb3b523577.tar.gz
org.eclipse.tcf-005675c5f5cf51818e997d23320994cb3b523577.tar.xz
org.eclipse.tcf-005675c5f5cf51818e997d23320994cb3b523577.zip
Target Explorer: Fix SWTException on shutdown
-rw-r--r--target_explorer/plugins/org.eclipse.tcf.te.tcf.filesystem/src/org/eclipse/tcf/te/tcf/filesystem/activator/UIPlugin.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/target_explorer/plugins/org.eclipse.tcf.te.tcf.filesystem/src/org/eclipse/tcf/te/tcf/filesystem/activator/UIPlugin.java b/target_explorer/plugins/org.eclipse.tcf.te.tcf.filesystem/src/org/eclipse/tcf/te/tcf/filesystem/activator/UIPlugin.java
index a4e465cf6..b33eae758 100644
--- a/target_explorer/plugins/org.eclipse.tcf.te.tcf.filesystem/src/org/eclipse/tcf/te/tcf/filesystem/activator/UIPlugin.java
+++ b/target_explorer/plugins/org.eclipse.tcf.te.tcf.filesystem/src/org/eclipse/tcf/te/tcf/filesystem/activator/UIPlugin.java
@@ -18,6 +18,7 @@ import org.eclipse.core.commands.Command;
import org.eclipse.core.commands.IExecutionListener;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.resource.ImageRegistry;
+import org.eclipse.swt.SWTException;
import org.eclipse.swt.graphics.Image;
import org.eclipse.tcf.te.tcf.filesystem.internal.ImageConsts;
import org.eclipse.tcf.te.tcf.filesystem.internal.autosave.SaveAllListener;
@@ -127,7 +128,8 @@ public class UIPlugin extends AbstractUIPlugin {
Command saveAllCmd = commandService.getCommand(IWorkbenchCommandConstants.FILE_SAVE_ALL);
saveAllCmd.removeExecutionListener(saveAllListener);
}
- clipboard.dispose();
+ // Ignore SWTException here, the display might be disposed already.
+ try { clipboard.dispose(); } catch (SWTException e) { /* ignored on purpose */ }
clipboard = null;
plugin = null;
super.stop(context);

Back to the top