<rdar://problem/10967188>
When using launch_info for launching with a target already set, we should just prepend the target's path as the first argument.
git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@151867 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/API/SBTarget.cpp b/source/API/SBTarget.cpp
index 58a6814..d4810f5 100644
--- a/source/API/SBTarget.cpp
+++ b/source/API/SBTarget.cpp
@@ -720,10 +720,9 @@
sb_process.SetSP (process_sp);
lldb_private::ProcessLaunchInfo &launch_info = sb_launch_info.ref();
- bool add_exe_as_first_argv = true; //launch_info.GetArguments().GetArgumentCount() == 0;
Module *exe_module = target_sp->GetExecutableModulePointer();
if (exe_module)
- launch_info.SetExecutableFile(exe_module->GetPlatformFileSpec(), add_exe_as_first_argv);
+ launch_info.SetExecutableFile(exe_module->GetPlatformFileSpec(), true);
const ArchSpec &arch_spec = target_sp->GetArchitecture();
if (arch_spec.IsValid())