Index: lisp/ChangeLog =================================================================== RCS file: /sources/emacs/emacs/lisp/ChangeLog,v retrieving revision 1.10655 diff -u -r1.10655 ChangeLog --- lisp/ChangeLog 7 Feb 2007 13:40:09 -0000 1.10655 +++ lisp/ChangeLog 7 Feb 2007 13:52:04 -0000 @@ -1,3 +1,8 @@ +2007-02-07 Per Cederqvist + + * diff-mode.el (diff-sanity-check-hunk): Don't reject the hunk + just because the diff was produced using "-p" (--show-c-function). + 2007-02-07 Vinicius Jose Latorre * ps-print.ps: The ps-print commands without face printing should not Index: lisp/diff-mode.el =================================================================== RCS file: /sources/emacs/emacs/lisp/diff-mode.el,v retrieving revision 1.94 diff -u -r1.94 diff-mode.el --- lisp/diff-mode.el 11 Jan 2007 16:52:59 -0000 1.94 +++ lisp/diff-mode.el 7 Feb 2007 13:52:04 -0000 @@ -1115,7 +1115,7 @@ ;; A context diff. ((eq (char-after) ?*) - (if (not (looking-at "\\*\\{15\\}\n\\*\\*\\* \\([0-9]+\\),\\([0-9]+\\) \\*\\*\\*\\*$")) + (if (not (looking-at "\\*\\{15\\}.*\n\\*\\*\\* \\([0-9]+\\),\\([0-9]+\\) \\*\\*\\*\\*$")) (error "Unrecognized context diff first hunk header format") (forward-line 2) (diff-sanity-check-context-hunk-half @@ -1131,7 +1131,7 @@ ;; A unified diff. ((eq (char-after) ?@) (if (not (looking-at - "@@ -[0-9]+,\\([0-9]+\\) \\+[0-9]+,\\([0-9]+\\) @@$")) + "@@ -[0-9]+,\\([0-9]+\\) \\+[0-9]+,\\([0-9]+\\) @@")) (error "Unrecognized unified diff hunk header format") (let ((before (string-to-number (match-string 1))) (after (string-to-number (match-string 2))))