aboutsummaryrefslogtreecommitdiff
path: root/git-send-email.perl
diff options
context:
space:
mode:
authorPeter Valdemar Mørch <peter@morch.com>2008-07-25 15:06:48 +0200
committerJunio C Hamano <gitster@pobox.com>2008-07-25 09:27:13 -0700
commit8892048d516fffab2000c2b47e006d8d8ebaa8c7 (patch)
treed4592c9291e4500c7eceeb39e89221f9f835572f /git-send-email.perl
parentf5242ebf0dcd858ae9c72f39aed9773696d7283d (diff)
downloadgit-8892048d516fffab2000c2b47e006d8d8ebaa8c7.tar.gz
git-8892048d516fffab2000c2b47e006d8d8ebaa8c7.tar.xz
send-email: find body-encoding correctly
In 8291db6 (git-send-email: add charset header if we add encoded 'From', 2007-11-16), "$1" is used from a regexp without using () to capture anything in $1. Later, when that value was used, it causes a warning about a variable being undefined, instead of using the correct value for comparison (not that it makes difference in the current code that does not do actual re-encoding). Signed-off-by: Peter Valdemar Mørch <peter@morch.com> 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 0b04ba32f..385ff7c21 100755
--- a/git-send-email.perl
+++ b/git-send-email.perl
@@ -850,7 +850,7 @@ foreach my $t (@files) {
}
elsif (/^Content-type:/i) {
$has_content_type = 1;
- if (/charset="?[^ "]+/) {
+ if (/charset="?([^ "]+)/) {
$body_encoding = $1;
}
push @xh, $_;