diff options
author | Chaoren Lin <chaorenl@google.com> | 2015-05-05 18:43:19 +0000 |
---|---|---|
committer | Chaoren Lin <chaorenl@google.com> | 2015-05-05 18:43:19 +0000 |
commit | ce36c4cee190067fa3e9b4d3f19eda6c986cefc4 (patch) | |
tree | 7f57ad25b66fc9b0185686b424143578475a987f | |
parent | 6ebc207703607521b4cab5b211332a2a86757538 (diff) | |
download | bcm5719-llvm-ce36c4cee190067fa3e9b4d3f19eda6c986cefc4.tar.gz bcm5719-llvm-ce36c4cee190067fa3e9b4d3f19eda6c986cefc4.zip |
Fix process launch from Windows host to Android target.
Summary:
- Denormalized path on Windows host causes bad `A` packet.
- Executables copied from Windows host doesn't have executable bits.
Reviewers: tberghammer, zturner, ovyalov
Reviewed By: ovyalov
Subscribers: tberghammer, lldb-commits
Differential Revision: http://reviews.llvm.org/D9492
llvm-svn: 236516
-rw-r--r-- | lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp | 4 | ||||
-rw-r--r-- | lldb/source/Target/Target.cpp | 1 |
2 files changed, 3 insertions, 2 deletions
diff --git a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp index 536df20dfb3..de382ac3607 100644 --- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp +++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp @@ -1312,7 +1312,7 @@ GDBRemoteCommunicationClient::SendArgumentsPacket (const ProcessLaunchInfo &laun const char *arg = NULL; const Args &launch_args = launch_info.GetArguments(); if (exe_file) - exe_path = exe_file.GetPath(); + exe_path = exe_file.GetPath(false); else { arg = launch_args.GetArgumentAtIndex(0); @@ -3221,7 +3221,7 @@ GDBRemoteCommunicationClient::SetFilePermissions (const char *path, if (response.GetChar() != 'F') return Error("invalid response to '%s' packet", packet); - return Error(response.GetU32(false, UINT32_MAX), eErrorTypePOSIX); + return Error(response.GetU32(UINT32_MAX), eErrorTypePOSIX); } static uint64_t diff --git a/lldb/source/Target/Target.cpp b/lldb/source/Target/Target.cpp index 02eab6b36c9..c643c0158f5 100644 --- a/lldb/source/Target/Target.cpp +++ b/lldb/source/Target/Target.cpp @@ -2378,6 +2378,7 @@ Target::Install (ProcessLaunchInfo *launch_info) module_sp->SetPlatformFileSpec(remote_file); if (is_main_executable) { + platform_sp->SetFilePermissions(remote_file.GetPath(false).c_str(), 0700); if (launch_info) launch_info->SetExecutableFile(remote_file, false); } |