Add a bunch of test cases to TestHelloWorld.py to exercise combinations of dwarf/dsym debug setup.
Among them are test cases to exercise SBTarget.AttachToProcessWithName(); we attach to "hello_world",
and verify that, after attachment, the currently selected target indeed matches "hello_world".
git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@133279 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/API/SBTarget.cpp b/source/API/SBTarget.cpp
index 78b67db..03333d9 100644
--- a/source/API/SBTarget.cpp
+++ b/source/API/SBTarget.cpp
@@ -330,6 +330,10 @@
if (sb_process.IsValid())
{
error.SetError (sb_process->Attach (name, wait_for));
+ // If we are doing synchronous mode, then wait for the
+ // process to stop!
+ if (m_opaque_sp->GetDebugger().GetAsyncExecution () == false)
+ sb_process->WaitForProcessToStop (NULL);
}
else
{