diff options
author | Junio C Hamano <gitster@pobox.com> | 2008-03-11 00:37:38 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2008-03-11 00:37:38 -0700 |
commit | b50396d16cb687eccb2c2c9160b30f17e20a543f (patch) | |
tree | 4e70bee79d4c36810b8f60034e5c53fe66aea560 | |
parent | 5b10a3c12439b262ccebb528a2db3945e7ebd061 (diff) | |
parent | c1ce83a5b64618a8a4ac313da82c156558cbe259 (diff) | |
download | git-b50396d16cb687eccb2c2c9160b30f17e20a543f.tar.gz git-b50396d16cb687eccb2c2c9160b30f17e20a543f.tar.xz |
Merge branch 'aw/maint-shortlog-blank-lines' into maint
* aw/maint-shortlog-blank-lines:
shortlog: take the first populated line of the description
-rw-r--r-- | builtin-shortlog.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/builtin-shortlog.c b/builtin-shortlog.c index fa8bc7d02..f08095bc9 100644 --- a/builtin-shortlog.c +++ b/builtin-shortlog.c @@ -74,11 +74,12 @@ static void insert_one_record(struct path_list *list, else free(buffer); + /* Skip any leading whitespace, including any blank lines. */ + while (*oneline && isspace(*oneline)) + oneline++; eol = strchr(oneline, '\n'); if (!eol) eol = oneline + strlen(oneline); - while (*oneline && isspace(*oneline) && *oneline != '\n') - oneline++; if (!prefixcmp(oneline, "[PATCH")) { char *eob = strchr(oneline, ']'); if (eob && (!eol || eob < eol)) |