aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman1996-04-16 22:33:07 +0000
committerRichard M. Stallman1996-04-16 22:33:07 +0000
commitc9b35eceec14a7e659c7d4e893f8d3b29e3d672a (patch)
tree406bef7835893b50f34bf979b2b94a6e91978a67
parenta92989c399a094529de8713c451f654b21265666 (diff)
downloademacs-c9b35eceec14a7e659c7d4e893f8d3b29e3d672a.tar.gz
emacs-c9b35eceec14a7e659c7d4e893f8d3b29e3d672a.zip
(vc-comment-ring): Initialise using make-ring.
(vc-clear-context): Initialise vc-comment-ring using make-ring. (vc-finish-logentry): Don't initialise vc-comment-ring here.
-rw-r--r--lisp/vc.el6
1 files changed, 2 insertions, 4 deletions
diff --git a/lisp/vc.el b/lisp/vc.el
index 4578d8211e3..1f649bf6abf 100644
--- a/lisp/vc.el
+++ b/lisp/vc.el
@@ -190,7 +190,7 @@ If nil, VC itself computes this value when it is first needed.")
190(defvar vc-dired-mode nil) 190(defvar vc-dired-mode nil)
191(make-variable-buffer-local 'vc-dired-mode) 191(make-variable-buffer-local 'vc-dired-mode)
192 192
193(defvar vc-comment-ring nil) 193(defvar vc-comment-ring (make-ring vc-maximum-comment-ring-size))
194(defvar vc-comment-ring-index nil) 194(defvar vc-comment-ring-index nil)
195(defvar vc-last-comment-match nil) 195(defvar vc-last-comment-match nil)
196 196
@@ -297,7 +297,7 @@ If nil, VC itself computes this value when it is first needed.")
297 (fillarray vc-file-prop-obarray nil) 297 (fillarray vc-file-prop-obarray nil)
298 ;; Note: there is potential for minor lossage here if there is an open 298 ;; Note: there is potential for minor lossage here if there is an open
299 ;; log buffer with a nonzero local value of vc-comment-ring-index. 299 ;; log buffer with a nonzero local value of vc-comment-ring-index.
300 (setq vc-comment-ring nil)) 300 (setq vc-comment-ring (make-ring vc-maximum-comment-ring-size)))
301 301
302(defun vc-file-clear-masterprops (file) 302(defun vc-file-clear-masterprops (file)
303 ;; clear all properties of FILE that were retrieved 303 ;; clear all properties of FILE that were retrieved
@@ -1006,8 +1006,6 @@ If nil, uses `change-log-default-name'."
1006 ;; Comment too long? 1006 ;; Comment too long?
1007 (vc-backend-logentry-check vc-log-file) 1007 (vc-backend-logentry-check vc-log-file)
1008 ;; Record the comment in the comment ring 1008 ;; Record the comment in the comment ring
1009 (if (null vc-comment-ring)
1010 (setq vc-comment-ring (make-ring vc-maximum-comment-ring-size)))
1011 (ring-insert vc-comment-ring (buffer-string)) 1009 (ring-insert vc-comment-ring (buffer-string))
1012 )) 1010 ))
1013 ;; Sync parent buffer in case the user modified it while editing the comment. 1011 ;; Sync parent buffer in case the user modified it while editing the comment.