# HG changeset patch # User Andreas Schwab # Date 1267983280 -3600 # Node ID 1cbedcbd728ff662139dfc6d131c53e958f73d1f # Parent ff09b16a7200f0d28fad376cec1b42f925a13e0e Don't end parsing rfc822 addresses prematurely (Bug#5692) * mail/rfc822.el (rfc822-addresses): Move catch clause down around call to rfc822-bad-address. (Bug#5692) diff -r ff09b16a7200 -r 1cbedcbd728f lisp/ChangeLog --- a/lisp/ChangeLog Sun Mar 07 09:45:53 2010 -0500 +++ b/lisp/ChangeLog Sun Mar 07 18:34:40 2010 +0100 @@ -1,3 +1,8 @@ +2010-03-07 Andreas Schwab + + * mail/rfc822.el (rfc822-addresses): Move catch clause down around + call to rfc822-bad-address. (Bug#5692) + 2010-03-07 Štěpán Němec (tiny change) * vc-git.el (vc-git-annotate-extract-revision-at-line): Use diff -r ff09b16a7200 -r 1cbedcbd728f lisp/mail/rfc822.el --- a/lisp/mail/rfc822.el Sun Mar 07 09:45:53 2010 -0500 +++ b/lisp/mail/rfc822.el Sun Mar 07 18:34:40 2010 +0100 @@ -296,26 +296,26 @@ ;; initial value to prevent rfc822-bad-address from ;; raising a wrong-type-argument error (rfc822-address-start (point))) - (catch 'address ; this is for rfc822-bad-address - (rfc822-nuke-whitespace) - (while (not (eobp)) - (setq rfc822-address-start (point)) - (setq tem - (cond ((rfc822-looking-at ?\,) - nil) - ((looking-at "[][\000-\037@;:\\.>)]") - (forward-char) - (rfc822-bad-address - (format "Strange character \\%c found" - (preceding-char)))) - (t - (rfc822-addresses-1 t)))) - (cond ((null tem)) - ((stringp tem) - (setq list (cons tem list))) - (t - (setq list (nconc (nreverse tem) list))))) - (nreverse list)))) + (rfc822-nuke-whitespace) + (while (not (eobp)) + (setq rfc822-address-start (point)) + (setq tem + (cond ((rfc822-looking-at ?\,) + nil) + ((looking-at "[][\000-\037@;:\\.>)]") + (forward-char) + (catch 'address ; this is for rfc822-bad-address + (rfc822-bad-address + (format "Strange character \\%c found" + (preceding-char))))) + (t + (rfc822-addresses-1 t)))) + (cond ((null tem)) + ((stringp tem) + (setq list (cons tem list))) + (t + (setq list (nconc (nreverse tem) list))))) + (nreverse list))) (and buf (kill-buffer buf)))))) (provide 'rfc822)