diff options
| author | root | 1990-11-26 22:52:07 +0000 |
|---|---|---|
| committer | root | 1990-11-26 22:52:07 +0000 |
| commit | 278fc732828c2d36d6025b84270b91d7ab3dd428 (patch) | |
| tree | ce32c6203a9b1bf8b8cb02e4ef0c1b9d502e939e | |
| parent | 67ea382e54cb3a981e547446ede3c313aabb6255 (diff) | |
| download | emacs-278fc732828c2d36d6025b84270b91d7ab3dd428.tar.gz emacs-278fc732828c2d36d6025b84270b91d7ab3dd428.zip | |
*** empty log message ***
| -rw-r--r-- | lisp/mail/rfc822.el | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/lisp/mail/rfc822.el b/lisp/mail/rfc822.el index 0209b939a5f..ec487be42b9 100644 --- a/lisp/mail/rfc822.el +++ b/lisp/mail/rfc822.el | |||
| @@ -239,19 +239,22 @@ | |||
| 239 | ;; an addr-spec, since many broken mailers output | 239 | ;; an addr-spec, since many broken mailers output |
| 240 | ;; "Hern K. Herklemeyer III | 240 | ;; "Hern K. Herklemeyer III |
| 241 | ;; <yank@megadeath.dod.gods-own-country>" | 241 | ;; <yank@megadeath.dod.gods-own-country>" |
| 242 | (cond ((= n 0)) | 242 | (let ((again t)) |
| 243 | ((> n 1) | 243 | (while again |
| 244 | (rfc822-bad-address "Missing route-spec")) | 244 | (or (= n 0) (bobp) (= (preceding-char) ?\ ) |
| 245 | ((= (preceding-char) ?\ )) | 245 | (insert ?\ )) |
| 246 | (t (insert ?\ ))) | 246 | (rfc822-snarf-word) |
| 247 | (rfc822-snarf-words) | 247 | (setq n (1+ n)) |
| 248 | (setq n (1+ n))) | 248 | (setq again (or (rfc822-looking-at ?.) |
| 249 | (looking-at "[^][\000-\037\177-\377 ()<>@,;:\\.]")))))) | ||
| 249 | ((= n 0) | 250 | ((= n 0) |
| 250 | (throw 'address nil)) | 251 | (throw 'address nil)) |
| 251 | ((= n 1) ; allow "foo" (losing unix seems to do this) | 252 | ((= n 1) ; allow "foo" (losing unix seems to do this) |
| 252 | (throw 'address | 253 | (throw 'address |
| 253 | (buffer-substring address-start (point)))) | 254 | (buffer-substring address-start (point)))) |
| 254 | ((or (eobp) (looking-at ",")) | 255 | ((> n 1) |
| 256 | (rfc822-bad-address "Missing comma between addresses or badly-formatted address")) | ||
| 257 | ((or (eobp) (= (following-char) ?,)) | ||
| 255 | (rfc822-bad-address "Missing comma or route-spec")) | 258 | (rfc822-bad-address "Missing comma or route-spec")) |
| 256 | (t | 259 | (t |
| 257 | (rfc822-bad-address "Strange character or missing comma"))))))) | 260 | (rfc822-bad-address "Strange character or missing comma"))))))) |