diff options
| author | Enrico Granata <egranata@apple.com> | 2015-11-19 21:17:56 +0000 |
|---|---|---|
| committer | Enrico Granata <egranata@apple.com> | 2015-11-19 21:17:56 +0000 |
| commit | 0cf8c0468d3cb69f6de72df382a2be270d4b22f6 (patch) | |
| tree | 075a26db73112eb31fff623199395e311773fad2 /lldb/source/Host | |
| parent | f71c9661dfd0d5eda96e26f8d6e3081bc177817c (diff) | |
| download | bcm5719-llvm-0cf8c0468d3cb69f6de72df382a2be270d4b22f6.tar.gz bcm5719-llvm-0cf8c0468d3cb69f6de72df382a2be270d4b22f6.zip | |
Fix an issue where LLDB would not launch argdumper correctly if there were spaces in the path to it
llvm-svn: 253599
Diffstat (limited to 'lldb/source/Host')
| -rw-r--r-- | lldb/source/Host/macosx/Host.mm | 5 | ||||
| -rw-r--r-- | lldb/source/Host/windows/Host.cpp | 2 |
2 files changed, 5 insertions, 2 deletions
diff --git a/lldb/source/Host/macosx/Host.mm b/lldb/source/Host/macosx/Host.mm index c3e2a898291..2db27a276e4 100644 --- a/lldb/source/Host/macosx/Host.mm +++ b/lldb/source/Host/macosx/Host.mm @@ -1366,8 +1366,11 @@ Host::ShellExpandArguments (ProcessLaunchInfo &launch_info) error.SetErrorStringWithFormat("could not find the lldb-argdumper tool: %s", expand_tool_spec.GetPath().c_str()); return error; } + + StreamString expand_tool_spec_stream; + expand_tool_spec_stream.Printf("\"%s\"",expand_tool_spec.GetPath().c_str()); - Args expand_command(expand_tool_spec.GetPath().c_str()); + Args expand_command(expand_tool_spec_stream.GetData()); expand_command.AppendArguments (launch_info.GetArguments()); int status; diff --git a/lldb/source/Host/windows/Host.cpp b/lldb/source/Host/windows/Host.cpp index 5439467708b..2c9a139df25 100644 --- a/lldb/source/Host/windows/Host.cpp +++ b/lldb/source/Host/windows/Host.cpp @@ -245,7 +245,7 @@ Host::ShellExpandArguments (ProcessLaunchInfo &launch_info) std::replace(quoted_cmd_string.begin(), quoted_cmd_string.end(), '\\', '/'); StreamString expand_command; - expand_command.Printf("%s %s", + expand_command.Printf("\"%s\" %s", expand_tool_spec.GetPath().c_str(), quoted_cmd_string.c_str()); |

