From bb19a13c0b3fe1ecdc1e46bbf2b06ffc1e25e04e Mon Sep 17 00:00:00 2001 From: Saleem Abdulrasool Date: Thu, 19 May 2016 05:13:57 +0000 Subject: second pass over removal of Mutex and Condition llvm-svn: 270024 --- lldb/source/API/SBCommandInterpreter.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'lldb/source/API/SBCommandInterpreter.cpp') diff --git a/lldb/source/API/SBCommandInterpreter.cpp b/lldb/source/API/SBCommandInterpreter.cpp index 21f431dac6a..dfa1709a349 100644 --- a/lldb/source/API/SBCommandInterpreter.cpp +++ b/lldb/source/API/SBCommandInterpreter.cpp @@ -398,7 +398,7 @@ SBCommandInterpreter::GetProcess () TargetSP target_sp(m_opaque_ptr->GetDebugger().GetSelectedTarget()); if (target_sp) { - Mutex::Locker api_locker(target_sp->GetAPIMutex()); + std::lock_guard guard(target_sp->GetAPIMutex()); process_sp = target_sp->GetProcessSP(); sb_process.SetSP(process_sp); } @@ -483,9 +483,9 @@ SBCommandInterpreter::SourceInitFileInHomeDirectory (SBCommandReturnObject &resu if (IsValid()) { TargetSP target_sp(m_opaque_ptr->GetDebugger().GetSelectedTarget()); - Mutex::Locker api_locker; + std::unique_lock lock; if (target_sp) - api_locker.Lock(target_sp->GetAPIMutex()); + lock = std::unique_lock(target_sp->GetAPIMutex()); m_opaque_ptr->SourceInitFile (false, result.ref()); } else @@ -508,9 +508,9 @@ SBCommandInterpreter::SourceInitFileInCurrentWorkingDirectory (SBCommandReturnOb if (IsValid()) { TargetSP target_sp(m_opaque_ptr->GetDebugger().GetSelectedTarget()); - Mutex::Locker api_locker; + std::unique_lock lock; if (target_sp) - api_locker.Lock(target_sp->GetAPIMutex()); + lock = std::unique_lock(target_sp->GetAPIMutex()); m_opaque_ptr->SourceInitFile (true, result.ref()); } else -- cgit v1.2.3