Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEugene Tarassov2012-02-24 13:49:23 -0500
committerEugene Tarassov2012-02-24 13:49:23 -0500
commit7a7d3ccebe9d49fb24071e2ae9c0d7cd17df161e (patch)
treefe3392c1143bb60441983c1d7abe1bf090c4d826
parent84405874331fde9f889f2cbfda8f783c28e11ba3 (diff)
downloadorg.eclipse.tcf-7a7d3ccebe9d49fb24071e2ae9c0d7cd17df161e.tar.gz
org.eclipse.tcf-7a7d3ccebe9d49fb24071e2ae9c0d7cd17df161e.tar.xz
org.eclipse.tcf-7a7d3ccebe9d49fb24071e2ae9c0d7cd17df161e.zip
TCF Debugger: fixed: NullPointerException if debugger connection is terminated immediately after it was started.
-rw-r--r--plugins/org.eclipse.tcf.debug.ui/src/org/eclipse/tcf/internal/debug/ui/model/TCFModel.java28
1 files changed, 15 insertions, 13 deletions
diff --git a/plugins/org.eclipse.tcf.debug.ui/src/org/eclipse/tcf/internal/debug/ui/model/TCFModel.java b/plugins/org.eclipse.tcf.debug.ui/src/org/eclipse/tcf/internal/debug/ui/model/TCFModel.java
index fad5acb87..ce9c82c04 100644
--- a/plugins/org.eclipse.tcf.debug.ui/src/org/eclipse/tcf/internal/debug/ui/model/TCFModel.java
+++ b/plugins/org.eclipse.tcf.debug.ui/src/org/eclipse/tcf/internal/debug/ui/model/TCFModel.java
@@ -580,19 +580,21 @@ public class TCFModel implements IElementContentProvider, IElementLabelProvider,
boolean done;
public void run() {
if (done) return;
- ArrayList<TCFNodeExecContext> nodes = new ArrayList<TCFNodeExecContext>();
- if (!searchSuspendedThreads(launch_node.getFilteredChildren(), nodes)) return;
- if (nodes.size() == 0) {
- setDebugViewSelection(launch_node, "Launch");
- }
- else if (nodes.size() == 1) {
- TCFNodeExecContext n = nodes.get(0);
- setDebugViewSelection(n, "Launch");
- }
- else {
- for (TCFNodeExecContext n : nodes) {
- String reason = n.getState().getData().suspend_reason;
- setDebugViewSelection(n, reason);
+ if (launch_node != null) {
+ ArrayList<TCFNodeExecContext> nodes = new ArrayList<TCFNodeExecContext>();
+ if (!searchSuspendedThreads(launch_node.getFilteredChildren(), nodes)) return;
+ if (nodes.size() == 0) {
+ setDebugViewSelection(launch_node, "Launch");
+ }
+ else if (nodes.size() == 1) {
+ TCFNodeExecContext n = nodes.get(0);
+ setDebugViewSelection(n, "Launch");
+ }
+ else {
+ for (TCFNodeExecContext n : nodes) {
+ String reason = n.getState().getData().suspend_reason;
+ setDebugViewSelection(n, reason);
+ }
}
}
done = true;

Back to the top