From 1b946bf6368353e9b56cbb3f29a1192706ff7ae2 Mon Sep 17 00:00:00 2001 From: Greg Clayton Date: Fri, 12 Nov 2010 00:49:23 +0000 Subject: Fixed an issue with the MachThread class where we might not get the initial thread basic info state and not realize that a thread was already suspended or if a thread was starting up and not ready to be displayed to the user (in an uninterruptable state). If it is not user ready yet, we don't add it to our list of threads that can be played with. llvm-svn: 118866 --- lldb/tools/debugserver/source/MacOSX/MachThreadList.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'lldb/tools/debugserver/source/MacOSX/MachThreadList.cpp') diff --git a/lldb/tools/debugserver/source/MacOSX/MachThreadList.cpp b/lldb/tools/debugserver/source/MacOSX/MachThreadList.cpp index 4f096b812de..db2a00a304a 100644 --- a/lldb/tools/debugserver/source/MacOSX/MachThreadList.cpp +++ b/lldb/tools/debugserver/source/MacOSX/MachThreadList.cpp @@ -237,7 +237,10 @@ MachThreadList::UpdateThreadList(MachProcess *process, bool update) { // We don't have this thread, lets add it. MachThreadSP threadSP(new MachThread(process, thread_list[idx])); - currThreads.push_back(threadSP); + // Make sure the thread is ready to be displayed and shown to users + // before we add this thread to our list... + if (threadSP->IsUserReady()) + currThreads.push_back(threadSP); } } -- cgit v1.2.3