summaryrefslogtreecommitdiffstats
path: root/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
diff options
context:
space:
mode:
authorPavel Labath <pavel@labath.sk>2018-08-31 05:34:03 +0000
committerPavel Labath <pavel@labath.sk>2018-08-31 05:34:03 +0000
commite7ec083f198a828fc0052652d5f051208391d34b (patch)
tree34aef4b039d58dc5e7ee09cfa1072b8c5befe1f6 /lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
parentd5fa57eb19609fc23c874f4653738432a8b8ad51 (diff)
downloadbcm5719-llvm-e7ec083f198a828fc0052652d5f051208391d34b.tar.gz
bcm5719-llvm-e7ec083f198a828fc0052652d5f051208391d34b.zip
Increase qHostInfo packet timeout
Host info computation can involve DNS traffic (to compute the remote host name). On very unreliable networks (such as free WiFi on trains), this can take several seconds to complete or timeout. Increase the qHostInfo timeout to account for this. llvm-svn: 341164
Diffstat (limited to 'lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp')
-rw-r--r--lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
index 919a9c4ed11..942447c090f 100644
--- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
+++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp
@@ -1134,6 +1134,9 @@ bool GDBRemoteCommunicationClient::GetHostInfo(bool force) {
Log *log(ProcessGDBRemoteLog::GetLogIfAnyCategoryIsSet(GDBR_LOG_PROCESS));
if (force || m_qHostInfo_is_valid == eLazyBoolCalculate) {
+ // host info computation can require DNS traffic and shelling out to external processes.
+ // Increase the timeout to account for that.
+ ScopedTimeout timeout(*this, seconds(10));
m_qHostInfo_is_valid = eLazyBoolNo;
StringExtractorGDBRemote response;
if (SendPacketAndWaitForResponse("qHostInfo", response, false) ==
OpenPOWER on IntegriCloud