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

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

[nongnu] elpa/slime 941657d07a 1/3: Fix slime-connect.


From: ELPA Syncer
Subject: [nongnu] elpa/slime 941657d07a 1/3: Fix slime-connect.
Date: Sat, 28 Sep 2024 10:00:48 -0400 (EDT)

branch: elpa/slime
commit 941657d07a12fcd0aa1db5a1a6376a6b8c3ae71a
Author: Stas Boukarev <stassats@gmail.com>
Commit: Stas Boukarev <stassats@gmail.com>

    Fix slime-connect.
---
 slime.el | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/slime.el b/slime.el
index b00bdba5f7..cfc83e539f 100644
--- a/slime.el
+++ b/slime.el
@@ -1875,8 +1875,9 @@ This is automatically synchronized from Lisp.")
         (setf (slime-machine-instance) instance))
       (cl-destructuring-bind (&key coding-systems) encoding
         (setf (slime-connection-coding-systems) coding-systems)))
-    (let ((args (let ((p (slime-inferior-process)))
-                  (if p (slime-inferior-lisp-args p)))))
+    (let* ((process (slime-inferior-process))
+           (args (and process
+                      (slime-inferior-lisp-args process))))
       (let ((name (plist-get args ':name)))
         (when name
           (unless (string= (slime-lisp-implementation-name) name)
@@ -1884,8 +1885,9 @@ This is automatically synchronized from Lisp.")
                   (slime-generate-connection-name (symbol-name name))))))
       (slime-load-contribs)
       (run-hooks 'slime-connected-hook)
-      (with-current-buffer (process-buffer (slime-inferior-process))
-        (setq slime-inferior-lisp-connected connection))
+      (when process
+        (with-current-buffer (process-buffer process)
+          (setq slime-inferior-lisp-connected connection)))
       (let ((fun (plist-get args ':init-function)))
         (when fun (funcall fun))))
     (message "Connected. %s" (slime-random-words-of-encouragement))))



reply via email to

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