aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lisp/ChangeLog6
-rw-r--r--lisp/mail/smtpmail.el10
2 files changed, 11 insertions, 5 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index bf8051e7c76..95a92f77e9f 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,9 @@
12004-02-04 Sam Steingold <sds@gnu.org>
2
3 * mail/smtpmail.el (smtpmail-try-auth-methods):
4 Do not try authentication when no mechanism is available.
5 Pass port-name as defaultport to `netrc-machine'.
6
12004-02-04 Stephen Eglen <stephen@gnu.org> 72004-02-04 Stephen Eglen <stephen@gnu.org>
2 8
3 * iswitchb.el (iswitchb-minibuffer-setup-hook): Update doc string 9 * iswitchb.el (iswitchb-minibuffer-setup-hook): Update doc string
diff --git a/lisp/mail/smtpmail.el b/lisp/mail/smtpmail.el
index bd9d5d7dd39..1730d131f60 100644
--- a/lisp/mail/smtpmail.el
+++ b/lisp/mail/smtpmail.el
@@ -488,15 +488,15 @@ This is relative to `smtpmail-queue-dir'.")
488 (mech (car (smtpmail-intersection smtpmail-auth-supported mechs))) 488 (mech (car (smtpmail-intersection smtpmail-auth-supported mechs)))
489 (cred (if (stringp smtpmail-auth-credentials) 489 (cred (if (stringp smtpmail-auth-credentials)
490 (let* ((netrc (netrc-parse smtpmail-auth-credentials)) 490 (let* ((netrc (netrc-parse smtpmail-auth-credentials))
491 (hostentry (netrc-machine 491 (port-name (format "%s" (or port "smtp")))
492 netrc host (format "%s" (or port "smtp")) 492 (hostentry (netrc-machine netrc host port-name
493 "smtp"))) 493 port-name)))
494 (when hostentry 494 (when hostentry
495 (list host port 495 (list host port
496 (netrc-get hostentry "login") 496 (netrc-get hostentry "login")
497 (netrc-get hostentry "password")))) 497 (netrc-get hostentry "password"))))
498 (smtpmail-find-credentials 498 (smtpmail-find-credentials
499 smtpmail-auth-credentials host port))) 499 smtpmail-auth-credentiaals host port)))
500 (passwd (when cred 500 (passwd (when cred
501 (or (smtpmail-cred-passwd cred) 501 (or (smtpmail-cred-passwd cred)
502 (read-passwd 502 (read-passwd
@@ -504,7 +504,7 @@ This is relative to `smtpmail-queue-dir'.")
504 (smtpmail-cred-server cred) 504 (smtpmail-cred-server cred)
505 (smtpmail-cred-port cred)))))) 505 (smtpmail-cred-port cred))))))
506 ret) 506 ret)
507 (when cred 507 (when (and cred mech)
508 (cond 508 (cond
509 ((eq mech 'cram-md5) 509 ((eq mech 'cram-md5)
510 (smtpmail-send-command process (format "AUTH %s" mech)) 510 (smtpmail-send-command process (format "AUTH %s" mech))