diff lisp/textmodes/fill.el @ 108662:30ebb77362b6

* textmodes/fill.el (fill-region): Don't fill past the end.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Tue, 18 May 2010 23:51:55 -0400
parents 1d1d5d9bd884
children d835100c3e8b 376148b31b5e
line wrap: on
line diff
--- a/lisp/textmodes/fill.el	Tue May 18 16:51:12 2010 -0400
+++ b/lisp/textmodes/fill.el	Tue May 18 23:51:55 2010 -0400
@@ -1036,7 +1036,7 @@
 	  (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))))