From: João Távora Date: Mon, 15 Jan 2024 12:32:51 +0000 (-0600) Subject: Jsonrpc: fix bug in jsonrpc--remove X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=950d08980d1ce32ced84c45bcb1797c195140593;p=emacs.git Jsonrpc: fix bug in jsonrpc--remove * lisp/jsonrpc.el (jsonrpc--remove): Check timer before cancelling it. (Version): Bump to 1.2.24 See https://github.com/joaotavora/eglot/issues/1342 (cherry picked from commit 43612103c221ffb300536798e2b8a8adb753f594) --- diff --git a/lisp/jsonrpc.el b/lisp/jsonrpc.el index f0f5842a0ee..7ff57daeb7d 100644 --- a/lisp/jsonrpc.el +++ b/lisp/jsonrpc.el @@ -4,7 +4,7 @@ ;; Author: João Távora ;; Keywords: processes, languages, extensions -;; Version: 1.0.23 +;; Version: 1.0.24 ;; Package-Requires: ((emacs "25.2")) ;; This is a GNU ELPA :core package. Avoid functionality that is not @@ -782,7 +782,7 @@ Return the full continuation (ID SUCCESS-FN ERROR-FN TIMER)" (if deferred-spec (remhash deferred-spec defs)) (when-let ((ass (assq id conts))) (cl-destructuring-bind (_ _ _ _ timer) ass - (cancel-timer timer)) + (when timer (cancel-timer timer))) (setf conts (delete ass conts)) ass)))