changeset 7553:e473c5ad9e7d

(server-done): Never kill buffer here. (server-buffer-done): Do it here, if temp file.
author Richard M. Stallman <rms@gnu.org>
date Thu, 19 May 1994 05:58:21 +0000
parents 371ae57ac9a8
children 9e9b7a0eebc6
files lisp/server.el
diffstat 1 files changed, 6 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/server.el	Thu May 19 05:56:21 1994 +0000
+++ b/lisp/server.el	Thu May 19 05:58:21 1994 +0000
@@ -251,7 +251,9 @@
 	  (save-excursion
 	    (set-buffer buffer)
 	    (setq server-buffer-clients nil))
-	  (bury-buffer buffer)))
+	  (if (server-temp-file-p buffer)
+	      (kill-buffer buffer)
+	    (bury-buffer buffer))))
     next-buffer))
 
 (defun server-temp-file-p (buffer)
@@ -269,19 +271,17 @@
 Then bury it, and return a suggested buffer to select next."
   (let ((buffer (current-buffer)))
     (if server-buffer-clients
-	(let (suggested-buffer)
+	(progn
  	  (if (server-temp-file-p buffer)
 	      ;; For a temp file, save, and do make a non-numeric backup
 	      ;; (unless make-backup-files is nil).
 	      (let ((version-control nil)
 		    (buffer-backed-up nil))
-		(save-buffer)
-		(kill-buffer buffer)
-		(setq suggested-buffer (current-buffer)))
+		(save-buffer))
 	    (if (and (buffer-modified-p)
 		     (y-or-n-p (concat "Save file " buffer-file-name "? ")))
 		(save-buffer buffer)))
-	  (or (server-buffer-done buffer) suggested-buffer)))))
+	  (server-buffer-done buffer)))))
 
 ;; If a server buffer is killed, release its client.
 ;; I'm not sure this is really a good idea--do you want the client