changeset 103622:f16f1c3154df

* server.el (server-buffer-done): Prevent kill-buffer from prompting by clearing the buffer modification flag (Bug#3696).
author Chong Yidong <cyd@stupidchicken.com>
date Mon, 29 Jun 2009 03:25:10 +0000
parents 444861df76cd
children e5da8db417c0
files lisp/ChangeLog lisp/server.el
diffstat 2 files changed, 10 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Sun Jun 28 20:25:49 2009 +0000
+++ b/lisp/ChangeLog	Mon Jun 29 03:25:10 2009 +0000
@@ -1,3 +1,8 @@
+2009-06-29  Chong Yidong  <cyd@stupidchicken.com>
+
+	* server.el (server-buffer-done): Prevent kill-buffer from
+	prompting by clearing the buffer modification flag (Bug#3696).
+
 2009-06-28  Michael McNamara  <mac@mail.brushroad.com>
 
 	* verilog-mode.el (verilog-beg-of-statement)
--- a/lisp/server.el	Sun Jun 28 20:25:49 2009 +0000
+++ b/lisp/server.el	Mon Jun 29 03:25:10 2009 +0000
@@ -1202,10 +1202,15 @@
 			 (not server-existing-buffer)))
 	      (setq killed t)
 	      (bury-buffer buffer)
+	      ;; Prevent kill-buffer from prompting (Bug#3696).
+	      (with-current-buffer buffer
+		(set-buffer-modified-p nil))
 	      (kill-buffer buffer))
 	    (unless killed
 	      (if (server-temp-file-p buffer)
 		  (progn
+		    (with-current-buffer buffer
+		      (set-buffer-modified-p nil))
 		    (kill-buffer buffer)
 		    (setq killed t))
 		(bury-buffer buffer)))))))