author | Stephen Boyd <bebarino@gmail.com> | |
Mon, 4 Oct 2010 07:05:24 +0000 (00:05 -0700) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Mon, 4 Oct 2010 07:12:13 +0000 (00:12 -0700) | ||
commit | 3c3bb51c3b205a6838b022896c9323d4b25bf392 | |
tree | 03eb8b996e1d3f851843139d20c33c7921adfa9b | tree | snapshot |
parent | 21802cd32805b19fa32e8e3594ee3914733d53d3 | commit | diff |
send-email: Don't leak To: headers between patches
If the first patch in a series has a To: header in the file and the
second patch in the series doesn't the address from the first patch will
be part of the To: addresses in the second patch. Fix this by treating the
to list like the cc list. Have an initial to list come from the command
line, user input and config options. Then build up a to list from each
patch and concatenate the two together before sending the patch. Finally,
reset the list after sending each patch so the To: headers from a patch
don't get used for the next one.
Reported-by: Viresh Kumar <viresh.kumar@st.com>
Signed-off-by: Stephen Boyd <bebarino@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
If the first patch in a series has a To: header in the file and the
second patch in the series doesn't the address from the first patch will
be part of the To: addresses in the second patch. Fix this by treating the
to list like the cc list. Have an initial to list come from the command
line, user input and config options. Then build up a to list from each
patch and concatenate the two together before sending the patch. Finally,
reset the list after sending each patch so the To: headers from a patch
don't get used for the next one.
Reported-by: Viresh Kumar <viresh.kumar@st.com>
Signed-off-by: Stephen Boyd <bebarino@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-send-email.perl | diff | blob | history | |
t/t9001-send-email.sh | diff | blob | history |