From fa835cd5728411bfd8f851e7327e11ad809a59d1 Mon Sep 17 00:00:00 2001 From: Thomas Rast Date: Thu, 26 Jun 2008 23:03:21 +0200 Subject: [PATCH] git-send-email: prevent undefined variable warnings if no encryption is set With the previous patch, not configuring any encryption (either on or off) would leave $smtp_encryption undefined. We simply set it to the empty string in that case. Signed-off-by: Thomas Rast Signed-off-by: Junio C Hamano --- git-send-email.perl | 3 +++ 1 file changed, 3 insertions(+) diff --git a/git-send-email.perl b/git-send-email.perl index 763072042..edb12c2aa 100755 --- a/git-send-email.perl +++ b/git-send-email.perl @@ -313,6 +313,9 @@ foreach my $setting (values %config_bool_settings) { ${$setting->[0]} = $setting->[1] unless (defined (${$setting->[0]})); } +# 'default' encryption is none -- this only prevents a warning +$smtp_encryption = '' unless (defined $smtp_encryption); + # Set CC suppressions my(%suppress_cc); if (@suppress_cc) { -- 2.26.2