emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/cider 7506cc4613: [Fix #3183] Fix time subtraction bug in


From: ELPA Syncer
Subject: [nongnu] elpa/cider 7506cc4613: [Fix #3183] Fix time subtraction bug in nrepl-client (#3184)
Date: Tue, 26 Apr 2022 16:58:21 -0400 (EDT)

branch: elpa/cider
commit 7506cc4613a5b71e5246fd83de347185b5d49c42
Author: Paul Eggert <eggert@cs.ucla.edu>
Commit: GitHub <noreply@github.com>

    [Fix #3183] Fix time subtraction bug in nrepl-client (#3184)
    
    Port to future Emacs, and fix bug on current and older Emacs when the clock 
modulo 2**16 wraps around.
---
 nrepl-client.el | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/nrepl-client.el b/nrepl-client.el
index 7eb1642ab5..92df9e9562 100644
--- a/nrepl-client.el
+++ b/nrepl-client.el
@@ -902,8 +902,9 @@ If TOOLING, use the tooling session rather than the 
standard session."
                  (setq time0 (current-time)))
         ;; break out in case we don't receive a response for a while
         (when (and nrepl-sync-request-timeout
-                   (> (cadr (time-subtract (current-time) time0))
-                      nrepl-sync-request-timeout))
+                   (time-less-p
+                    nrepl-sync-request-timeout
+                    (time-subtract nil time0)))
           (error "Sync nREPL request timed out %s" request)))
       ;; Clean up the response, otherwise we might repeatedly ask for input.
       (nrepl-dict-put response "status" (remove "need-input" status))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]