From ab0c07c0209012ff0010c2c24303ee7a4c33a514 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Tue, 18 May 2010 23:51:55 -0400 Subject: [PATCH] * textmodes/fill.el (fill-region): Don't fill past the end. Fixes: debbugs:6201 --- lisp/ChangeLog | 4 ++++ lisp/textmodes/fill.el | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) 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)))) -- 2.39.2