From 3ac503e042bca5f4c6c1c661a8b5d17fef9555fc Mon Sep 17 00:00:00 2001 From: Johnny Chen Date: Tue, 20 Dec 2011 01:22:03 +0000 Subject: Work in progress for: rdar://problem/10577182 Audit lldb API impl for places where we need to perform a NULL check Add a NULL check for SBTarget.AttachToProcessWithName() so it will not hang. llvm-svn: 146948 --- lldb/source/API/SBTarget.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lldb/source/API/SBTarget.cpp') diff --git a/lldb/source/API/SBTarget.cpp b/lldb/source/API/SBTarget.cpp index 059f91c4444..967ea6b836f 100644 --- a/lldb/source/API/SBTarget.cpp +++ b/lldb/source/API/SBTarget.cpp @@ -379,7 +379,7 @@ SBTarget::AttachToProcessWithName ) { SBProcess sb_process; - if (m_opaque_sp) + if (name && m_opaque_sp) { Mutex::Locker api_locker (m_opaque_sp->GetAPIMutex()); -- cgit v1.2.3