From: Richard M. Stallman Date: Wed, 27 Aug 1997 02:33:40 +0000 (+0000) Subject: (mail-strip-quoted-names): Retain one whitespace X-Git-Tag: emacs-20.1~385 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=3a295f7b0d200b6d9c54684d031a63532fc05451;p=emacs.git (mail-strip-quoted-names): Retain one whitespace character between addresses. --- diff --git a/lisp/mail/mail-utils.el b/lisp/mail/mail-utils.el index 69701cc196f..a970f866dc9 100644 --- a/lisp/mail/mail-utils.el +++ b/lisp/mail/mail-utils.el @@ -150,7 +150,7 @@ Return a modified address list." ;; strip `quoted' names (This is supposed to hack `"Foo Bar" ') (setq pos 0) (while (setq pos (string-match - "[ \t]*\"\\([^\"\\]\\|\\\\.\\|\\\\\n\\)*\"[ \t\n]*" + "\\([ \t]?\\)[ \t]*\"\\([^\"\\]\\|\\\\.\\|\\\\\n\\)*\"[ \t\n]*" address pos)) ;; If the next thing is "@", we have "foo bar"@host. Leave it. (if (and (> (length address) (match-end 0)) @@ -158,7 +158,7 @@ Return a modified address list." (setq pos (match-end 0)) (setq address (mail-string-delete address - pos (match-end 0))))) + (match-end 1) (match-end 0))))) ;; Retain only part of address in <> delims, if there is such a thing. (while (setq pos (string-match "\\(,\\s-*\\|\\`\\)[^,]*<\\([^>,:]*>\\)" address))