summaryrefslogtreecommitdiff
path: root/git-send-email.perl
diff options
context:
space:
mode:
authorÆvar Arnfjörð Bjarmason <avarab@gmail.com>2010-09-30 13:43:03 (GMT)
committerJunio C Hamano <gitster@pobox.com>2010-09-30 19:20:33 (GMT)
commitd5c7d69d0fa25f1b5df50e12280a622f28319f16 (patch)
treebb090978a228970be983ceaba3fe4012e1fe9ef9 /git-send-email.perl
parentff483897317b5379e189d6bd782270dd08c09966 (diff)
downloadgit-d5c7d69d0fa25f1b5df50e12280a622f28319f16.zip
git-d5c7d69d0fa25f1b5df50e12280a622f28319f16.tar.gz
git-d5c7d69d0fa25f1b5df50e12280a622f28319f16.tar.bz2
send-email: sanitize_address use qq["foo"], not "\"foo\""
Perl provides an alternate quote syntax which can make using "" inside interpolated strings easier to read. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.comReviewed-by: Avery Pennarun <apenwarr@gmail.com> Reviewed-by: Jeff King <peff@peff.net> > Signed-off-by: Junio C Hamano <gitster@pobox.com>
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 1bf090a..c012b95 100755
--- a/git-send-email.perl
+++ b/git-send-email.perl
@@ -881,7 +881,7 @@ sub sanitize_address {
# double quotes are needed if specials or CTLs are included
elsif ($recipient_name =~ /[][()<>@,;:\\".\000-\037\177]/) {
$recipient_name =~ s/(["\\\r])/\\$1/g;
- $recipient_name = "\"$recipient_name\"";
+ $recipient_name = qq["$recipient_name"];
}
return "$recipient_name $recipient_addr";