Be sure to take the mutex when the destructor is called in case other threads are using these lists and those other threads have the mutex locked.
llvm-svn: 178262
diff --git a/lldb/source/Target/StackFrameList.cpp b/lldb/source/Target/StackFrameList.cpp
index d9d5544..39aa1bc 100644
--- a/lldb/source/Target/StackFrameList.cpp
+++ b/lldb/source/Target/StackFrameList.cpp
@@ -65,6 +65,9 @@
//----------------------------------------------------------------------
StackFrameList::~StackFrameList()
{
+ // Call clear since this takes a lock and clears the stack frame list
+ // in case another thread is currently using this stack frame list
+ Clear();
}
void