mirror of
https://github.com/git/git.git
synced 2026-01-10 10:13:33 +00:00
send-email: Honour SMTP domain when using TLS
git-send-email sends two SMTP EHLOs when using TLS encryption, however only the first, unencrypted EHLO uses the SMTP domain that can be optionally specified by the user (--smtp-domain). This is because the call to hello() that produces the second, encrypted EHLO does not pass the SMTP domain as an argument, and hence a default of 'localhost.localdomain' is used instead. Fix by passing in the SMTP domain in this call. Signed-off-by: Matthew Daley <mattjd@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
69cf7bfd13
commit
155b940f7a
@@ -1015,7 +1015,7 @@ X-Mailer: git-send-email $gitversion
|
|||||||
$smtp_encryption = '';
|
$smtp_encryption = '';
|
||||||
# Send EHLO again to receive fresh
|
# Send EHLO again to receive fresh
|
||||||
# supported commands
|
# supported commands
|
||||||
$smtp->hello();
|
$smtp->hello($smtp_domain);
|
||||||
} else {
|
} else {
|
||||||
die "Server does not support STARTTLS! ".$smtp->message;
|
die "Server does not support STARTTLS! ".$smtp->message;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user