aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGerd Moellmann2000-03-01 10:28:44 +0000
committerGerd Moellmann2000-03-01 10:28:44 +0000
commit7d3ff86996a57fbdbe9a9fa94f18e0beac70b12c (patch)
tree4eed88c4ba8ba4147a86678daafefaea7b63ecb2
parent6b62286235528eac4fc7ffe9eb7478c1cce24ddc (diff)
downloademacs-7d3ff86996a57fbdbe9a9fa94f18e0beac70b12c.tar.gz
emacs-7d3ff86996a57fbdbe9a9fa94f18e0beac70b12c.zip
(list-diary-entries): Don't try to go forward at
the end of the buffer.
-rw-r--r--lisp/calendar/diary-lib.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/calendar/diary-lib.el b/lisp/calendar/diary-lib.el
index c8d88a2549d..4fdebb81e12 100644
--- a/lisp/calendar/diary-lib.el
+++ b/lisp/calendar/diary-lib.el
@@ -255,10 +255,12 @@ These hooks have the following distinct roles:
255 (let ((buffer-read-only nil) 255 (let ((buffer-read-only nil)
256 (diary-modified (buffer-modified-p)) 256 (diary-modified (buffer-modified-p))
257 (mark (regexp-quote diary-nonmarking-symbol))) 257 (mark (regexp-quote diary-nonmarking-symbol)))
258 ;; First and last characters must be ^M or \n for
259 ;; selective display to work properly
258 (goto-char (1- (point-max))) 260 (goto-char (1- (point-max)))
259 (if (not (looking-at "\^M\\|\n")) 261 (if (not (looking-at "\^M\\|\n"))
260 (progn 262 (progn
261 (forward-char 1) 263 (goto-char (point-max))
262 (insert-string "\^M"))) 264 (insert-string "\^M")))
263 (goto-char (point-min)) 265 (goto-char (point-min))
264 (if (not (looking-at "\^M\\|\n")) 266 (if (not (looking-at "\^M\\|\n"))