changeset 12822:6fb78108d62d

(server-buffer-done): Pause between client commands, but not after the last one.
author Richard M. Stallman <rms@gnu.org>
date Thu, 10 Aug 1995 22:07:41 +0000
parents 259b1abdec5f
children c1fcd8660aba
files lisp/server.el
diffstat 1 files changed, 6 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/server.el	Thu Aug 10 20:31:27 1995 +0000
+++ b/lisp/server.el	Thu Aug 10 22:07:41 1995 +0000
@@ -248,6 +248,7 @@
   (let ((running (eq (process-status server-process) 'run))
 	(next-buffer nil)
 	(killed nil)
+	(first t)
 	(old-clients server-clients))
     (while old-clients
       (let ((client (car old-clients)))
@@ -266,12 +267,13 @@
 	(if (cdr client) nil
 	  (if running
 	      (progn
+		;; Don't send emacsserver two commands in close succession.
+		;; It cannot handle that.
+		(or first (sit-for 1))
+		(setq first nil)
 		(send-string server-process 
 			     (format "Close: %s Done\n" (car client)))
-		(server-log (format "Close: %s Done\n" (car client)))
-		;; Don't send emacsserver two commands in close succession.
-		;; It cannot handle that.
-		(sit-for 1)))
+		(server-log (format "Close: %s Done\n" (car client)))))
 	  (setq server-clients (delq client server-clients))))
       (setq old-clients (cdr old-clients)))
     (if (and (bufferp buffer) (buffer-name buffer))