Treat smtp-auth method from auth-info as a symbol

The lookup of the SMTP auth method is done based on symbols, but
sometimes the requested value comes from `auth-info', in which case it
is a string, so call `intern-soft' to convert it to a symbol (which
does nothing if it's already a symbol).

* lisp/mail/smtpmail.el (smtpmail-try-auth-methods): Call
`intern-soft' on the smtp-auth key's value.  (Bug#57373)

Do not merge to master
This commit is contained in:
Robert Pluim 2022-08-25 18:13:16 +02:00
parent 9e03e29c4e
commit ba64d09156

View file

@ -578,7 +578,7 @@ for `smtpmail-try-auth-method'.")
(setq password (funcall password)))
(let ((result (catch 'done
(if (and mech user password)
(smtpmail-try-auth-method process mech user password)
(smtpmail-try-auth-method process (intern-soft mech) user password)
;; No mechanism, or no credentials.
mech))))
(if (stringp result)