aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThien-Thi Nguyen2006-06-05 15:46:00 +0000
committerThien-Thi Nguyen2006-06-05 15:46:00 +0000
commit58ce5535fd79ab1d48153eb82b7a0963b6aa20f1 (patch)
tree77470d0e8c90f60bbbfbc05c72d56cbb61066d04
parent63fbb6441f2aee292a11621e375ce2e52797d6c0 (diff)
downloademacs-58ce5535fd79ab1d48153eb82b7a0963b6aa20f1.tar.gz
emacs-58ce5535fd79ab1d48153eb82b7a0963b6aa20f1.zip
(vc-process-filter): Inhibit undo
info collection around call to insert. (vc-setup-buffer): Likewise for call to erase-buffer. (vc-do-command): Likewise for call to process-file.
-rw-r--r--lisp/ChangeLog7
-rw-r--r--lisp/vc.el12
2 files changed, 15 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index d6efd8f8526..7cf001f1196 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,10 @@
12006-06-05 Thien-Thi Nguyen <ttn@gnu.org>
2
3 * vc.el (vc-process-filter): Inhibit undo
4 info collection around call to insert.
5 (vc-setup-buffer): Likewise for call to erase-buffer.
6 (vc-do-command): Likewise for call to process-file.
7
12006-06-05 Nick Roberts <nickrob@snap.net.nz> 82006-06-05 Nick Roberts <nickrob@snap.net.nz>
2 9
3 * progmodes/gud.el (gud-menu-map): Use a conditional help echo 10 * progmodes/gud.el (gud-menu-map): Use a conditional help echo
diff --git a/lisp/vc.el b/lisp/vc.el
index 61b8aa05a4b..54237800e3c 100644
--- a/lisp/vc.el
+++ b/lisp/vc.el
@@ -894,10 +894,12 @@ However, before executing BODY, find FILE, and after BODY, save buffer."
894 894
895(defun vc-process-filter (p s) 895(defun vc-process-filter (p s)
896 "An alternative output filter for async process P. 896 "An alternative output filter for async process P.
897The only difference with the default filter is to insert S after markers." 897One difference with the default filter is that this inserts S after markers.
898Another is that undo information is not kept."
898 (with-current-buffer (process-buffer p) 899 (with-current-buffer (process-buffer p)
899 (save-excursion 900 (save-excursion
900 (let ((inhibit-read-only t)) 901 (let ((buffer-undo-list t)
902 (inhibit-read-only t))
901 (goto-char (process-mark p)) 903 (goto-char (process-mark p))
902 (insert s) 904 (insert s)
903 (set-marker (process-mark p) (point)))))) 905 (set-marker (process-mark p) (point))))))
@@ -914,7 +916,8 @@ BUF defaults to \"*vc*\", can be a string and will be created if necessary."
914 (set (make-local-variable 'vc-parent-buffer-name) 916 (set (make-local-variable 'vc-parent-buffer-name)
915 (concat " from " (buffer-name camefrom))) 917 (concat " from " (buffer-name camefrom)))
916 (setq default-directory olddir) 918 (setq default-directory olddir)
917 (let ((inhibit-read-only t)) 919 (let ((buffer-undo-list t)
920 (inhibit-read-only t))
918 (erase-buffer)))) 921 (erase-buffer))))
919 922
920(defun vc-exec-after (code) 923(defun vc-exec-after (code)
@@ -1003,7 +1006,8 @@ that is inserted into the command line before the filename."
1003 (vc-exec-after 1006 (vc-exec-after
1004 `(unless (active-minibuffer-window) 1007 `(unless (active-minibuffer-window)
1005 (message "Running %s in the background... done" ',command)))) 1008 (message "Running %s in the background... done" ',command))))
1006 (setq status (apply 'process-file command nil t nil squeezed)) 1009 (let ((buffer-undo-list t))
1010 (setq status (apply 'process-file command nil t nil squeezed)))
1007 (when (and (not (eq t okstatus)) 1011 (when (and (not (eq t okstatus))
1008 (or (not (integerp status)) 1012 (or (not (integerp status))
1009 (and okstatus (< okstatus status)))) 1013 (and okstatus (< okstatus status))))