[slime-devel] [patch] restarting SWANK with globally redirected io

Stanisław Halik sthalik at test123.ltd.pl
Thu Aug 13 17:56:08 UTC 2009


Here's a patch for SWANK that fixes *globally-redirect-io* set to T
when restarting SWANK, for instance by typing M-x slime when a REPL is
already present.

I can't attach files since I'm posting through GMANE so it's included in
the message. If whitespace breaks use the -l flag for patch(1).

diff --git a/swank.lisp b/swank.lisp
index d6cf047..ac314fb 100644
--- a/swank.lisp
+++ b/swank.lisp
@@ -1488,8 +1488,8 @@ dynamic binding."
   "The symbols naming standard io streams.")
 
 (defun init-global-stream-redirection ()
-  (when *globally-redirect-io*
-    (assert (not *saved-global-streams*) () "Streams already redirected.")
+  (when (and *globally-redirect-io*
+             (not *saved-global-streams*))
     (mapc #'setup-stream-indirection
           (append *standard-output-streams*
                   *standard-input-streams*





More information about the slime-devel mailing list