summaryrefslogtreecommitdiffstats
path: root/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
diff options
context:
space:
mode:
authorOleksiy Vyalov <ovyalov@google.com>2015-10-21 19:34:26 +0000
committerOleksiy Vyalov <ovyalov@google.com>2015-10-21 19:34:26 +0000
commit9fe526c2e741351387d572093d65da2018d6b88a (patch)
tree56799a886db0c714fcc3b08fc20ae9f5a8920819 /lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
parent526b5f9cd4794794d278db42c56f074404aa9a5e (diff)
downloadbcm5719-llvm-9fe526c2e741351387d572093d65da2018d6b88a.tar.gz
bcm5719-llvm-9fe526c2e741351387d572093d65da2018d6b88a.zip
Add domain socket support to gdb-remote protocol and lldb-server.
http://reviews.llvm.org/D13881 llvm-svn: 250933
Diffstat (limited to 'lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp')
-rw-r--r--lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp15
1 files changed, 11 insertions, 4 deletions
diff --git a/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp b/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
index 5b6f9794f5a..8ed7e45f1a2 100644
--- a/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
+++ b/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
@@ -3562,15 +3562,22 @@ ProcessGDBRemote::LaunchAndConnectToDebugserver (const ProcessInfo &process_info
// Set hostname being NULL to do the reverse connect where debugserver
// will bind to port zero and it will communicate back to us the port
// that we will connect to
- const char *hostname = NULL;
+ const char *hostname = nullptr;
uint16_t port = 0;
#endif
- error = m_gdb_comm.StartDebugserverProcess (hostname,
- port,
+ StreamString url_str;
+ const char* url = nullptr;
+ if (hostname != nullptr)
+ {
+ url_str.Printf("%s:%u", hostname, port);
+ url = url_str.GetData();
+ }
+
+ error = m_gdb_comm.StartDebugserverProcess (url,
GetTarget().GetPlatform().get(),
debugserver_launch_info,
- port);
+ &port);
if (error.Success ())
m_debugserver_pid = debugserver_launch_info.GetProcessID();
OpenPOWER on IntegriCloud