aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp
diff options
context:
space:
mode:
authorOleksiy Vyalov <ovyalov@google.com>2015-01-14 01:31:27 +0000
committerOleksiy Vyalov <ovyalov@google.com>2015-01-14 01:31:27 +0000
commit477182922547410b2e4d83110120a15b912928b9 (patch)
tree9220814b7c90fa45c1c81497d818da6adf22dc6b /lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp
parent63a951eb1c59a1f4e4a66278ce1a322867700109 (diff)
downloadllvm-477182922547410b2e4d83110120a15b912928b9.zip
llvm-477182922547410b2e4d83110120a15b912928b9.tar.gz
llvm-477182922547410b2e4d83110120a15b912928b9.tar.bz2
Extend PipePosix with support for named pipes/timeout-based IO and integrate it with GDBRemoteCommunication / lldb-gdbserver - include reviews fixes.
http://reviews.llvm.org/D6954 llvm-svn: 225923
Diffstat (limited to 'lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp')
-rw-r--r--lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp
index 2a944a7..919fa54 100644
--- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp
+++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunication.cpp
@@ -876,15 +876,14 @@ GDBRemoteCommunication::StartDebugserverProcess (const char *hostname,
{
if (named_pipe_path[0])
{
- const auto timeout = std::chrono::microseconds(10 * 1000000);
- error = port_named_pipe.OpenAsReaderWithTimeout(named_pipe_path, false, timeout);
+ error = port_named_pipe.OpenAsReader(named_pipe_path, false);
if (error.Success())
{
char port_cstr[256];
port_cstr[0] = '\0';
size_t num_bytes = sizeof(port_cstr);
// Read port from pipe with 10 second timeout.
- error = port_named_pipe.ReadWithTimeout(port_cstr, num_bytes, timeout, num_bytes);
+ error = port_named_pipe.ReadWithTimeout(port_cstr, num_bytes, std::chrono::microseconds(10 * 1000000), num_bytes);
if (error.Success())
{
assert (num_bytes > 0 && port_cstr[num_bytes-1] == '\0');