summaryrefslogtreecommitdiffstats
path: root/lldb/source/API/SBValue.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/source/API/SBValue.cpp')
-rw-r--r--lldb/source/API/SBValue.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/lldb/source/API/SBValue.cpp b/lldb/source/API/SBValue.cpp
index 4ed2c7d1ffe..03ac1273b73 100644
--- a/lldb/source/API/SBValue.cpp
+++ b/lldb/source/API/SBValue.cpp
@@ -348,6 +348,9 @@ SBValue::GetChildAtIndex (uint32_t idx, lldb::DynamicValueType use_dynamic)
{
lldb::ValueObjectSP child_sp;
+ if (m_opaque_sp->GetUpdatePoint().GetTarget())
+ Mutex::Locker api_locker (m_opaque_sp->GetUpdatePoint().GetTarget()->GetAPIMutex());
+
if (m_opaque_sp)
{
child_sp = m_opaque_sp->GetChildAtIndex (idx, true);
@@ -401,6 +404,10 @@ SBValue::GetChildMemberWithName (const char *name, lldb::DynamicValueType use_dy
lldb::ValueObjectSP child_sp;
const ConstString str_name (name);
+ if (m_opaque_sp->GetUpdatePoint().GetTarget())
+ Mutex::Locker api_locker (m_opaque_sp->GetUpdatePoint().GetTarget()->GetAPIMutex());
+
+
if (m_opaque_sp)
{
child_sp = m_opaque_sp->GetChildMemberWithName (str_name, true);
OpenPOWER on IntegriCloud