diff options
author | Junio C Hamano <gitster@pobox.com> | 2018-05-08 15:59:31 +0900 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-05-08 15:59:31 +0900 |
commit | c50f76aa9d40203650fe36107adbad42104f8cf6 (patch) | |
tree | 52fb05da7942010dea27cc55fe037a2d83b75666 | |
parent | Merge branch 'nd/submodule-status-fix' (diff) | |
parent | send-email: avoid duplicate In-Reply-To/References (diff) | |
download | tgif-c50f76aa9d40203650fe36107adbad42104f8cf6.tar.xz |
Merge branch 'sa/send-email-dedup-some-headers'
When fed input that already has In-Reply-To: and/or References:
headers and told to add the same information, "git send-email"
added these headers separately, instead of appending to an existing
one, which is a violation of the RFC. This has been corrected.
* sa/send-email-dedup-some-headers:
send-email: avoid duplicate In-Reply-To/References
-rwxr-xr-x | git-send-email.perl | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/git-send-email.perl b/git-send-email.perl index 2fa7818ca9..7157397fd0 100755 --- a/git-send-email.perl +++ b/git-send-email.perl @@ -1642,10 +1642,15 @@ foreach my $t (@files) { elsif (/^Content-Transfer-Encoding: (.*)/i) { $xfer_encoding = $1 if not defined $xfer_encoding; } + elsif (/^In-Reply-To: (.*)/i) { + $in_reply_to = $1; + } + elsif (/^References: (.*)/i) { + $references = $1; + } elsif (!/^Date:\s/i && /^[-A-Za-z]+:\s+\S/) { push @xh, $_; } - } else { # In the traditional # "send lots of email" format, |