changeset 103514:9b52cad1866b

(appt-make-list): Fix off-by-one error caused by differing behavior of \n and ^ in strings. (Bug#3385)
author Glenn Morris <rgm@gnu.org>
date Mon, 22 Jun 2009 06:29:59 +0000
parents 93c102cc8dd2
children 6244d336a786
files lisp/ChangeLog lisp/calendar/appt.el
diffstat 2 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Mon Jun 22 06:27:00 2009 +0000
+++ b/lisp/ChangeLog	Mon Jun 22 06:29:59 2009 +0000
@@ -1,5 +1,8 @@
 2009-06-22  Glenn Morris  <rgm@gnu.org>
 
+	* calendar/appt.el (appt-make-list): Fix off-by-one error caused by
+	differing behavior of \n and ^ in strings.  (Bug#3385)
+
 	* emacs-lisp/cl-indent.el: Remove leading "*" from defcustom docs.
 
 	* emacs-lisp/lisp-mode.el (lisp-indent-offset): Fix safe-local-variable
--- a/lisp/calendar/appt.el	Mon Jun 22 06:27:00 2009 +0000
+++ b/lisp/calendar/appt.el	Mon Jun 22 06:29:59 2009 +0000
@@ -568,7 +568,7 @@
                                  (match-end 0)))
                            ;; Get the whole string for this appointment.
                            (appt-time-string
-                            (substring time-string beg (if end (1- end))))
+                            (substring time-string beg end))
                            (appt-time (list (appt-convert-time only-time)))
                            (time-msg (list appt-time appt-time-string)))
                       ;; Add this appointment to appt-time-msg-list.