Support port number in Gnus X-Message-SMTP-Method header
* lisp/gnus/message.el (message-multi-smtp-send-mail): Try to parse service as port number. If it succeeds, use parsed number, else use supplied service name as before (bug#24653). (This only matters on some operating systems.)
This commit is contained in:
parent
45e3753762
commit
57442b6812
1 changed files with 5 additions and 3 deletions
|
@ -4676,9 +4676,11 @@ that instead."
|
|||
(message-send-mail-with-sendmail))
|
||||
((equal (car method) "smtp")
|
||||
(require 'smtpmail)
|
||||
(let ((smtpmail-smtp-server (nth 1 method))
|
||||
(smtpmail-smtp-service (nth 2 method))
|
||||
(smtpmail-smtp-user (or (nth 3 method) smtpmail-smtp-user)))
|
||||
(let* ((smtpmail-smtp-server (nth 1 method))
|
||||
(service (nth 2 method))
|
||||
(port (string-to-number service))
|
||||
(smtpmail-smtp-service (if (> port 0) port service))
|
||||
(smtpmail-smtp-user (or (nth 3 method) smtpmail-smtp-user)))
|
||||
(message-smtpmail-send-it)))
|
||||
(t
|
||||
(error "Unknown method %s" method))))))
|
||||
|
|
Loading…
Add table
Reference in a new issue