[slime-devel] SBCL, multiple (zombie?) processes problems

Alan Caulkins fatman at maxint.net
Tue Sep 14 11:04:06 UTC 2004


I posted this issue, along with a patch, the first of August. Luke Gorrie
replied:

> The fix looks right, but it's not working for me. Actually I seem to
> be having some weird problems reconnecting to SBCL when running `M-x
> slime' repeatedly.
>
> Thanks for the patch, I'll need to investigate the weirdness a bit
> before applying.

Unfortunately I was stupid and forgot to put the patch in unidiff format,
and I think it fell through the cracks.

Someone said they thought the issue was fixed in a recent version of SBCL,
but I've just tested Slime 1.0 with SBCL 0.8.14 on Slackware 10.0, and the
issue still exists. My (now unidiff) patch was made against slime-1.0beta,
but it still seems to fix the problem.

The patch is included below.

-A

Maxint Consulting

			Linux: The ultimate video game.


Common subdirectories: slime-1.0beta/doc and lib/emacs/slime-1.0beta/doc
diff -u slime-1.0beta/swank.lisp lib/emacs/slime-1.0beta/swank.lisp
--- slime-1.0beta/swank.lisp	Tue Aug  3 06:39:02 2004
+++ lib/emacs/slime-1.0beta/swank.lisp	Wed Aug  4 23:21:57 2004
@@ -504,6 +504,10 @@
       (setf (connection.repl-thread connection) repl-thread)
       connection)))

+(defun cleanup-connection-threads (connection)
+  (kill-thread (connection.control-thread connection))
+  (kill-thread (connection.repl-thread connection)))
+
 (defun repl-loop (connection)
   (with-connection (connection)
     (loop (handle-request connection))))
@@ -610,7 +614,8 @@
       (make-connection :socket-io socket-io
 		       :read #'read-from-control-thread
 		       :send #'send-to-control-thread
-		       :serve-requests #'spawn-threads-for-connection))
+		       :serve-requests #'spawn-threads-for-connection
+                       :cleanup #'cleanup-connection-threads))
      (:sigio
       (make-connection :socket-io socket-io
                        :read #'read-from-socket-io
Only in lib/emacs/slime-1.0beta: swank.lisp~





More information about the slime-devel mailing list