diff --git a/debug/org.eclipse.cdt.debug.mi.core/ChangeLog b/debug/org.eclipse.cdt.debug.mi.core/ChangeLog index 2cf2a140d9c..83856982c5f 100644 --- a/debug/org.eclipse.cdt.debug.mi.core/ChangeLog +++ b/debug/org.eclipse.cdt.debug.mi.core/ChangeLog @@ -1,3 +1,8 @@ +2006-08-31 Mikhail Khodjaiants + Bug 155816: NPE thrown by info threads + Applied patch from James Blackburn (jamesblackburn+eclipse@gmail.com). + * Target.java + 2006-08-22 Mikhail Khodjaiants Bug 145758: Unable to use the default command factories. * MANIFEST.MF diff --git a/debug/org.eclipse.cdt.debug.mi.core/cdi/org/eclipse/cdt/debug/mi/core/cdi/model/Target.java b/debug/org.eclipse.cdt.debug.mi.core/cdi/org/eclipse/cdt/debug/mi/core/cdi/model/Target.java index f4e17c5101f..1786001f6eb 100644 --- a/debug/org.eclipse.cdt.debug.mi.core/cdi/org/eclipse/cdt/debug/mi/core/cdi/model/Target.java +++ b/debug/org.eclipse.cdt.debug.mi.core/cdi/org/eclipse/cdt/debug/mi/core/cdi/model/Target.java @@ -345,6 +345,7 @@ public class Target extends SessionObject implements ICDITarget { } else { ids = info.getThreadIds(); names = info.getThreadNames(); + currentThreadId = info.getCurrentThread(); } if (ids != null && ids.length > 0) { cthreads = new Thread[ids.length]; @@ -362,7 +363,6 @@ public class Target extends SessionObject implements ICDITarget { // Provide a dummy. cthreads = new Thread[]{new Thread(this, 0)}; } - currentThreadId = info.getCurrentThread(); // FIX: When attaching there is no thread selected // We will choose the first one as a workaround. if (currentThreadId == 0 && cthreads.length > 0) {