Mercurial > emacs
changeset 28880:a0115904eda4
(comint-read-input-ring): Move reference to
comint-input-ring-size outside of the save-excursion. It was
causing the default value to be the only one ever seen.
author | Gerd Moellmann <gerd@gnu.org> |
---|---|
date | Thu, 11 May 2000 20:34:51 +0000 |
parents | 2a918425ca15 |
children | 083f5ccb5a94 |
files | lisp/comint.el |
diffstat | 1 files changed, 6 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/comint.el Thu May 11 19:29:55 2000 +0000 +++ b/lisp/comint.el Thu May 11 20:34:51 2000 +0000 @@ -762,10 +762,11 @@ (message "Cannot read history file %s" comint-input-ring-file-name))) (t - (let ((history-buf (get-buffer-create " *temp*")) - (file comint-input-ring-file-name) - (count 0) - (ring (make-ring comint-input-ring-size))) + (let* ((history-buf (get-buffer-create " *temp*")) + (file comint-input-ring-file-name) + (count 0) + (size comint-input-ring-size) + (ring (make-ring size))) (unwind-protect (save-excursion (set-buffer history-buf) @@ -775,7 +776,7 @@ ;; Save restriction in case file is already visited... ;; Watch for those date stamps in history files! (goto-char (point-max)) - (while (and (< count comint-input-ring-size) + (while (and (< count size) (re-search-backward "^[ \t]*\\([^#\n].*\\)[ \t]*$" nil t)) (let (start end history)