# HG changeset patch # User Jim Blandy # Date 727022957 0 # Node ID 29bcc2c88773ce690fb99572507710342fa3204b # Parent c77a852fda5f9473f9b4648f64e1f70283710f84 * page-ext.el (next-page): Correctly handle negative page count. diff -r c77a852fda5f -r 29bcc2c88773 lisp/textmodes/page-ext.el --- a/lisp/textmodes/page-ext.el Thu Jan 14 14:48:57 1993 +0000 +++ b/lisp/textmodes/page-ext.el Thu Jan 14 14:49:17 1993 +0000 @@ -341,7 +341,10 @@ nil (goto-char (point-max))) (setq count (1- count))) - (while (and (< count 0) (not (bobp))) + ;; If COUNT is negative, we want to go back -COUNT + 1 page boundaries. + ;; The first page boundary we reach is the top of the current page, + ;; which doesn't count. + (while (and (< count 1) (not (bobp))) (if (re-search-backward page-delimiter nil t) (goto-char (match-beginning 0)) (goto-char (point-min)))