(message-idna-to-ascii-rhs-1): Don't call `idna-to-ascii'
authorReiner Steib <Reiner.Steib@gmx.de>
Sat, 1 Dec 2007 11:55:23 +0000 (11:55 +0000)
committerReiner Steib <Reiner.Steib@gmx.de>
Sat, 1 Dec 2007 11:55:23 +0000 (11:55 +0000)
if rhs is ASCII.

lisp/ChangeLog
lisp/message.el

index bfeb763..7c29666 100644 (file)
@@ -1,3 +1,8 @@
+2007-12-01  Reiner Steib  <Reiner.Steib@gmx.de>
+
+       * message.el (message-idna-to-ascii-rhs-1): Don't call `idna-to-ascii'
+       if rhs is ASCII.
+
 2007-11-28  Reiner Steib  <Reiner.Steib@gmx.de>
 
        * tls.el (tls-hostmismatch, open-tls-stream): Checkdoc cleanup.
index ea997c2..6f5cd90 100644 (file)
@@ -5547,7 +5547,9 @@ subscribed address (and not the additional To and Cc header contents)."
                        (mapcar 'downcase
                                (mapcar
                                 'car (mail-header-parse-addresses field))))))
-       (setq ace (downcase (idna-to-ascii rhs)))
+       (setq ace (if (string-match "\\`[[:ascii:]]+\\'" rhs)
+                     rhs
+                   (downcase (idna-to-ascii rhs))))
        (when (and (not (equal rhs ace))
                   (or (not (eq message-use-idna 'ask))
                       (y-or-n-p (format "Replace %s with %s in %s:? "