From 470b452628d80e89ee869b6b86af6c536ba0b24d Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Fri, 19 Feb 2010 21:55:33 -0800 Subject: mailinfo: do not strip leading spaces even for a header line Signed-off-by: Junio C Hamano diff --git a/builtin-mailinfo.c b/builtin-mailinfo.c index a50ac22..ce2ef6b 100644 --- a/builtin-mailinfo.c +++ b/builtin-mailinfo.c @@ -779,8 +779,7 @@ static int handle_commit_msg(struct strbuf *line) return 0; if (still_looking) { - strbuf_ltrim(line); - if (!line->len) + if (!line->len || (line->len == 1 && line->buf[0] == '\n')) return 0; } diff --git a/t/t5100/msg0015 b/t/t5100/msg0015 index 9577238..4abb3d5 100644 --- a/t/t5100/msg0015 +++ b/t/t5100/msg0015 @@ -1,2 +1,2 @@ -- a list + - a list - of stuff -- cgit v0.10.2-6-g49f6