From 8bc5c04a715ee0746df2bcd7e0924f4119140ad2 Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Mon, 6 Feb 2006 21:35:25 -0800 Subject: [PATCH 1/1] [PATCH] mailinfo: reset CTE after each multipart If the first part uses quoted-printable to protect iso8859-1 name in the commit log, and the second part was plain ascii text patchfile without even Content-Transfer-Encoding subheader, we incorrectly tried to decode the patch as quoted printable. Signed-off-by: Junio C Hamano --- mailinfo.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mailinfo.c b/mailinfo.c index 0265a29a..ff2d4d40 100644 --- a/mailinfo.c +++ b/mailinfo.c @@ -707,6 +707,9 @@ static void handle_multipart_body(void) if (!len) { if (handle_multipart_one_part() < 0) return; + /* Reset per part headers */ + transfer_encoding = TE_DONTCARE; + charset[0] = 0; } else check_subheader_line(line, len); -- 2.11.0