summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: cc41cd2)
raw | patch | inline | side by side (parent: cc41cd2)
author | Michael S. Tsirkin <mst@mellanox.co.il> | |
Thu, 27 Jul 2006 14:03:43 +0000 (17:03 +0300) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Fri, 28 Jul 2006 02:33:06 +0000 (19:33 -0700) |
Mail I get sometimes has multiple From lines, like this:
From Majordomo@vger.kernel.org Thu Jul 27 16:39:36 2006
>From mtsirkin Thu Jul 27 16:39:36 2006
Received: from yok.mtl.com [10.0.8.11]
...
which confuses git-mailinfo since that does not recognize >From
as a valid header line.
This patch makes it recognize >From XXX as a valid header line.
Signed-off-by: Michael S. Tsirkin <mst@mellanox.co.il>
Signed-off-by: Junio C Hamano <junkio@cox.net>
From Majordomo@vger.kernel.org Thu Jul 27 16:39:36 2006
>From mtsirkin Thu Jul 27 16:39:36 2006
Received: from yok.mtl.com [10.0.8.11]
...
which confuses git-mailinfo since that does not recognize >From
as a valid header line.
This patch makes it recognize >From XXX as a valid header line.
Signed-off-by: Michael S. Tsirkin <mst@mellanox.co.il>
Signed-off-by: Junio C Hamano <junkio@cox.net>
builtin-mailinfo.c | patch | blob | history |
diff --git a/builtin-mailinfo.c b/builtin-mailinfo.c
index ac53f76f689fdc0a44b6e4921dc08b880e1349b0..05dc1bfe71976ed24a4bb8cafb0036b8f93fadd6 100644 (file)
--- a/builtin-mailinfo.c
+++ b/builtin-mailinfo.c
break;
}
/* Count mbox From headers as headers */
- if (!ofs && !memcmp(line, "From ", 5))
+ if (!ofs && (!memcmp(line, "From ", 5) || !memcmp(line, ">From ", 6)))
ofs = 1;
return ofs;
}