diff options
Diffstat (limited to 'builtin/shortlog.c')
-rw-r--r-- | builtin/shortlog.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/builtin/shortlog.c b/builtin/shortlog.c index e32be3993c..bfc082e584 100644 --- a/builtin/shortlog.c +++ b/builtin/shortlog.c @@ -118,15 +118,15 @@ static void read_from_stdin(struct shortlog *log) struct strbuf author = STRBUF_INIT; struct strbuf oneline = STRBUF_INIT; - while (strbuf_getline(&author, stdin, '\n') != EOF) { + while (strbuf_getline_lf(&author, stdin) != EOF) { const char *v; if (!skip_prefix(author.buf, "Author: ", &v) && !skip_prefix(author.buf, "author ", &v)) continue; - while (strbuf_getline(&oneline, stdin, '\n') != EOF && + while (strbuf_getline_lf(&oneline, stdin) != EOF && oneline.len) ; /* discard headers */ - while (strbuf_getline(&oneline, stdin, '\n') != EOF && + while (strbuf_getline_lf(&oneline, stdin) != EOF && !oneline.len) ; /* discard blanks */ insert_one_record(log, v, oneline.buf); |