Browse Source

git-send-email: Do not attempt to STARTTLS more than once

With the previous TLS patch, send-email would attempt to STARTTLS at
the beginning of every mail, despite reusing the last connection.  We
simply skip further encryption checks after successful TLS initiation.

Signed-off-by: Thomas Rast <trast@student.ethz.ch>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
maint
Thomas Rast 17 years ago committed by Junio C Hamano
parent
commit
6cbf8b00fb
  1. 1
      git-send-email.perl

1
git-send-email.perl

@ -772,6 +772,7 @@ X-Mailer: git-send-email $gitversion @@ -772,6 +772,7 @@ X-Mailer: git-send-email $gitversion
if ($smtp->code == 220) {
$smtp = Net::SMTP::SSL->start_SSL($smtp)
or die "STARTTLS failed! ".$smtp->message;
$smtp_encryption = '';
} else {
die "Server does not support STARTTLS! ".$smtp->message;
}

Loading…
Cancel
Save