changeset 20661:e3498221274f

(vc-finish-logentry): Move killing the log buffer after the operation in case that fails.
author Karl Heuer <kwzh@gnu.org>
date Sun, 18 Jan 1998 03:27:05 +0000
parents deb167dcda0b
children 910d4cdbf81f
files lisp/vc.el
diffstat 1 files changed, 5 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/vc.el	Sun Jan 18 03:21:25 1998 +0000
+++ b/lisp/vc.el	Sun Jan 18 03:27:05 1998 +0000
@@ -1182,17 +1182,18 @@
 	(log-version vc-log-version)
 	(log-entry (buffer-string))
 	(after-hook vc-log-after-operation-hook))
-    ;; Return to "parent" buffer of this checkin and remove checkin window
     (pop-to-buffer vc-parent-buffer)
-    (let ((logbuf (get-buffer "*VC-log*")))
-      (delete-windows-on logbuf)
-      (kill-buffer logbuf))
     ;; OK, do it to it
     (save-excursion
       (funcall log-operation 
 	       log-file
 	       log-version
 	       log-entry))
+    ;; Remove checkin window (after the checkin so that if that fails
+    ;; we don't zap the *VC-log* buffer and the typing therein).
+    (let ((logbuf (get-buffer "*VC-log*")))
+      (delete-windows-on logbuf)
+      (kill-buffer logbuf))
     ;; Now make sure we see the expanded headers
     (if buffer-file-name
 	(vc-resynch-window buffer-file-name vc-keep-workfiles t))