From: Stefan Monnier Date: Wed, 19 May 2010 03:51:55 +0000 (-0400) Subject: * textmodes/fill.el (fill-region): Don't fill past the end. X-Git-Tag: emacs-pretest-23.2.90~139^2~173 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=ab0c07c0209012ff0010c2c24303ee7a4c33a514;p=emacs.git * textmodes/fill.el (fill-region): Don't fill past the end. Fixes: debbugs:6201 --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 1da680a68f9..3346fcf497a 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2010-05-19 Uday S Reddy (tiny change) + + * textmodes/fill.el (fill-region): Don't fill past the end (bug#6201). + 2010-05-18 Stefan Monnier * subr.el (read-quoted-char): Resolve modifiers after key diff --git a/lisp/textmodes/fill.el b/lisp/textmodes/fill.el index 1b3cc8dc4d8..da6e02bfa2f 100644 --- a/lisp/textmodes/fill.el +++ b/lisp/textmodes/fill.el @@ -1036,7 +1036,7 @@ space does not end a sentence, so don't break a line there." (fill-forward-paragraph -1)) (if (< (point) beg) (goto-char beg)) - (if (>= (point) initial) + (if (and (>= (point) initial) (< (point) end)) (setq fill-pfx (fill-region-as-paragraph (point) end justify nosqueeze)) (goto-char end))))