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
This commit is contained in:
Junio C Hamano 2015-09-21 12:27:15 -07:00
commit b6bd2d0964

View File

@ -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}'";
}