summaryrefslogtreecommitdiff
path: root/git-send-email.perl
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2015-09-21 12:27:15 -0700
committerJunio C Hamano <gitster@pobox.com>2015-09-21 12:27:15 -0700
commitb6bd2d09646fbacd3fd9d859fd219707812baae4 (patch)
tree9e685741a2c62aaba632f8d063d1d11f4b0b4551 /git-send-email.perl
parente646ab9cf83025e1000db6ec3c1716f978b099f2 (diff)
parent904f6e7c15ab50c02048f50002d8f72b9ed74075 (diff)
downloadgit-b6bd2d09646fbacd3fd9d859fd219707812baae4.tar.gz
Merge branch 'bn/send-email-smtp-auth-error-message-fix'
Fix a minor regression brought in to "git send-email" by a recent addition of the "--smtp-auth" option. * bn/send-email-smtp-auth-error-message-fix: send-email: fix uninitialized var warning for $smtp_auth
Diffstat (limited to 'git-send-email.perl')
-rwxr-xr-xgit-send-email.perl2
1 files changed, 1 insertions, 1 deletions
diff --git a/git-send-email.perl b/git-send-email.perl
index c5a3f766f7..e3ff44b4d0 100755
--- a/git-send-email.perl
+++ b/git-send-email.perl
@@ -1136,7 +1136,7 @@ sub smtp_auth_maybe {
# Check mechanism naming as defined in:
# https://tools.ietf.org/html/rfc4422#page-8
- if ($smtp_auth !~ /^(\b[A-Z0-9-_]{1,20}\s*)*$/) {
+ if ($smtp_auth && $smtp_auth !~ /^(\b[A-Z0-9-_]{1,20}\s*)*$/) {
die "invalid smtp auth: '${smtp_auth}'";
}