[slime-cvs] CVS update: slime/swank.lisp

Helmut Eller heller at common-lisp.net
Sun Oct 30 15:07:09 UTC 2005


Update of /project/slime/cvsroot/slime
In directory common-lisp.net:/tmp/cvs-serv15056

Modified Files:
	swank.lisp 
Log Message:
(simple-serve-requests): Close the connection at the end.
Date: Sun Oct 30 16:07:08 2005
Author: heller

Index: slime/swank.lisp
diff -u slime/swank.lisp:1.348 slime/swank.lisp:1.349
--- slime/swank.lisp:1.348	Sun Oct 23 10:47:54 2005
+++ slime/swank.lisp	Sun Oct 30 16:07:07 2005
@@ -383,9 +383,7 @@
                 :name "Swank"))
         ((:fd-handler :sigio)
          (add-fd-handler socket (lambda () (serve))))
-        ((nil)
-         (unwind-protect (loop do (serve) while dont-close)
-           (close-socket socket))))
+        ((nil) (loop do (serve) while dont-close)))
       port)))
 
 (defun serve-connection (socket style dont-close external-format)
@@ -475,7 +473,8 @@
 Return an output stream suitable for writing program output.
 
 This is an optimized way for Lisp to deliver output to Emacs."
-  (let* ((socket (create-socket *loopback-interface* *dedicated-output-stream-port*))
+  (let* ((socket (create-socket *loopback-interface* 
+                                *dedicated-output-stream-port*))
          (port (local-port socket)))
     (encode-message `(:open-dedicated-output-stream ,port) socket-io)
     (accept-authenticated-connection
@@ -697,7 +696,8 @@
 
 (defun simple-serve-requests (connection)
   (with-reader-error-handler (connection)
-    (loop (handle-request connection))))
+    (unwind-protect (loop (handle-request connection))
+      (close-connection connection))))
 
 (defun read-from-socket-io ()
   (let ((event (decode-message (current-socket-io))))




More information about the slime-cvs mailing list