Skip to main content
aboutsummaryrefslogtreecommitdiffstats
path: root/dsf
diff options
context:
space:
mode:
Diffstat (limited to 'dsf')
-rw-r--r--dsf/org.eclipse.cdt.examples.dsf.pda.ui/src/org/eclipse/cdt/examples/dsf/pda/ui/PDAAdapterFactory.java1
-rw-r--r--dsf/org.eclipse.cdt.examples.dsf.pda/src/org/eclipse/cdt/examples/dsf/pda/launch/PDALaunch.java9
2 files changed, 9 insertions, 1 deletions
diff --git a/dsf/org.eclipse.cdt.examples.dsf.pda.ui/src/org/eclipse/cdt/examples/dsf/pda/ui/PDAAdapterFactory.java b/dsf/org.eclipse.cdt.examples.dsf.pda.ui/src/org/eclipse/cdt/examples/dsf/pda/ui/PDAAdapterFactory.java
index 4bd0b575f82..d78413542e8 100644
--- a/dsf/org.eclipse.cdt.examples.dsf.pda.ui/src/org/eclipse/cdt/examples/dsf/pda/ui/PDAAdapterFactory.java
+++ b/dsf/org.eclipse.cdt.examples.dsf.pda.ui/src/org/eclipse/cdt/examples/dsf/pda/ui/PDAAdapterFactory.java
@@ -48,6 +48,7 @@ public class PDAAdapterFactory implements IAdapterFactory
if (session == null) return null;
SessionAdapterSet adapterSet = PDAUIPlugin.getDefault().getAdapterSet(launch);
+ if (adapterSet == null) return null;
// Returns the adapter type for the launch object.
if (adapterType.equals(IElementContentProvider.class)) return adapterSet.fViewModelAdapter;
diff --git a/dsf/org.eclipse.cdt.examples.dsf.pda/src/org/eclipse/cdt/examples/dsf/pda/launch/PDALaunch.java b/dsf/org.eclipse.cdt.examples.dsf.pda/src/org/eclipse/cdt/examples/dsf/pda/launch/PDALaunch.java
index 5af41839c3e..b15042d4972 100644
--- a/dsf/org.eclipse.cdt.examples.dsf.pda/src/org/eclipse/cdt/examples/dsf/pda/launch/PDALaunch.java
+++ b/dsf/org.eclipse.cdt.examples.dsf.pda/src/org/eclipse/cdt/examples/dsf/pda/launch/PDALaunch.java
@@ -245,7 +245,6 @@ implements ITerminate
DsfSession.endSession(fSession);
// endSession takes a full dispatch to distribute the
// session-ended event, finish step only after the dispatch.
- fExecutor.shutdown();
fireTerminate();
rm.setStatus(getStatus());
@@ -262,4 +261,12 @@ implements ITerminate
Platform.getAdapterManager().loadAdapter(this, adapter.getName());
return super.getAdapter(adapter);
}
+
+ @Override
+ public void launchRemoved(ILaunch launch) {
+ if (this.equals(launch)) {
+ fExecutor.shutdown();
+ }
+ super.launchRemoved(launch);
+ }
}

Back to the top