From: Glenn Morris Date: Thu, 2 Apr 2009 06:33:18 +0000 (+0000) Subject: (diary-cyclic): Check for +ve N. X-Git-Tag: emacs-pretest-23.0.93~253 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=6f8eab73b40369408c6e7e009615b8e709ad03b3;p=emacs.git (diary-cyclic): Check for +ve N. --- diff --git a/lisp/calendar/diary-lib.el b/lisp/calendar/diary-lib.el index 57f18f69137..0081170d8ac 100644 --- a/lisp/calendar/diary-lib.el +++ b/lisp/calendar/diary-lib.el @@ -1912,6 +1912,8 @@ and %s by the ordinal ending of that number (that is, `st', `nd', An optional parameter MARK specifies a face or single-character string to use when highlighting the day in the calendar." + (or (> n 0) + (error "Day count must be positive")) (let* ((diff (- (calendar-absolute-from-gregorian date) (calendar-absolute-from-gregorian (diary-make-date month day year))))