Author: Jim Ingham
Date: 2021-05-17T10:49:47-07:00
New Revision: bd5751f3d249ec0798060bd98c07272174c52af0

URL: 
https://github.com/llvm/llvm-project/commit/bd5751f3d249ec0798060bd98c07272174c52af0
DIFF: 
https://github.com/llvm/llvm-project/commit/bd5751f3d249ec0798060bd98c07272174c52af0.diff

LOG: Reset the wakeup timeout when we re-enter the continue wait.

Differential Revision: https://reviews.llvm.org/D102562

Added: 
    

Modified: 
    lldb/source/Plugins/Process/gdb-remote/GDBRemoteClientBase.cpp

Removed: 
    


################################################################################
diff  --git a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteClientBase.cpp 
b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteClientBase.cpp
index 61429b7af26c..a4c71e864a76 100644
--- a/lldb/source/Plugins/Process/gdb-remote/GDBRemoteClientBase.cpp
+++ b/lldb/source/Plugins/Process/gdb-remote/GDBRemoteClientBase.cpp
@@ -61,6 +61,9 @@ StateType 
GDBRemoteClientBase::SendContinuePacketAndWaitForResponse(
                                                    kWakeupInterval);
   for (;;) {
     PacketResult read_result = ReadPacket(response, computed_timeout, false);
+    // Reset the computed_timeout to the default value in case we are going
+    // round again.
+    computed_timeout = std::min(interrupt_timeout, kWakeupInterval);
     switch (read_result) {
     case PacketResult::ErrorReplyTimeout: {
       std::lock_guard<std::mutex> lock(m_mutex);


        
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to