diff options
author | Greg Clayton <gclayton@apple.com> | 2013-05-29 23:31:14 +0000 |
---|---|---|
committer | Greg Clayton <gclayton@apple.com> | 2013-05-29 23:31:14 +0000 |
commit | 83793fc18868a9671d49f9122467039037a4c3e6 (patch) | |
tree | 113c321f9ffa52bd9fb904dc61784c6171a44dc2 /lldb/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp | |
parent | 086e085efa6c08a49892b938c33e35f689d9370f (diff) | |
download | bcm5719-llvm-83793fc18868a9671d49f9122467039037a4c3e6.tar.gz bcm5719-llvm-83793fc18868a9671d49f9122467039037a4c3e6.zip |
<rdar://problem/13956179>
Cleaned up the thread updating code in the OperatingSystemPython class. It doesn't need to clear the "new_thread_list" anymore as it is always empty.
It also now assigns the "core_thread_list" to "new_thread_list" if no threads are detected through python.
llvm-svn: 182893
Diffstat (limited to 'lldb/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp')
-rw-r--r-- | lldb/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp | 19 |
1 files changed, 3 insertions, 16 deletions
diff --git a/lldb/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp b/lldb/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp index 9979a02a80e..4cfe38e5840 100644 --- a/lldb/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp +++ b/lldb/source/Plugins/OperatingSystem/Python/OperatingSystemPython.cpp @@ -207,21 +207,6 @@ OperatingSystemPython::UpdateThreadList (ThreadList &old_thread_list, PythonDictionary thread_dict(threads_list.GetItemAtIndex(i)); if (thread_dict) { - if (thread_dict.GetItemForKey("core")) - { - // We have some threads that are saying they are on a "core", which means - // they map the threads that are gotten from the lldb_private::Process subclass - // so clear the new threads list so the core threads don't show up - new_thread_list.Clear(); - break; - } - } - } - for (i=0; i<num_threads; ++i) - { - PythonDictionary thread_dict(threads_list.GetItemAtIndex(i)); - if (thread_dict) - { ThreadSP thread_sp (CreateThreadFromThreadInfo (thread_dict, core_thread_list, old_thread_list, NULL)); if (thread_sp) new_thread_list.AddThread(thread_sp); @@ -230,8 +215,10 @@ OperatingSystemPython::UpdateThreadList (ThreadList &old_thread_list, } } + // No new threads added from the thread info array gotten from python, just + // display the core threads. if (new_thread_list.GetSize(false) == 0) - new_thread_list = old_thread_list; + new_thread_list = core_thread_list; return new_thread_list.GetSize(false) > 0; } |