Mercurial > emacs
changeset 80246:3629f9a94638
(diff-sanity-check-hunk): Only accept an empty line if
we still expect more lines.
author | Stefan Monnier <monnier@iro.umontreal.ca> |
---|---|
date | Fri, 29 Feb 2008 02:40:10 +0000 |
parents | ad818454aedc |
children | c384fbc8c569 |
files | lisp/ChangeLog lisp/diff-mode.el |
diffstat | 2 files changed, 7 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/ChangeLog Fri Feb 29 02:02:39 2008 +0000 +++ b/lisp/ChangeLog Fri Feb 29 02:40:10 2008 +0000 @@ -1,3 +1,8 @@ +2008-02-29 Stefan Monnier <monnier@iro.umontreal.ca> + + * diff-mode.el (diff-sanity-check-hunk): Only accept an empty line if + we still expect more lines. + 2008-02-28 Juri Linkov <juri@jurta.org> * startup.el (normal-splash-screen): Add argument `concise'.
--- a/lisp/diff-mode.el Fri Feb 29 02:02:39 2008 +0000 +++ b/lisp/diff-mode.el Fri Feb 29 02:40:10 2008 +0000 @@ -1251,7 +1251,8 @@ (cond ((and diff-valid-unified-empty-line ;; Not just (eolp) so we don't infloop at eob. - (eq (char-after) ?\n)) + (eq (char-after) ?\n) + (> before 0) (> after 0)) (decf before) (decf after) t) ((and (zerop before) (zerop after)) nil) ((or (< before 0) (< after 0))