Skip to content

Commit

Permalink
hash-object: read --stdin-paths with strbuf_getline()
Browse files Browse the repository at this point in the history
The list of paths could have been written with a DOS editor.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Junio C Hamano committed Jan 15, 2016
1 parent 1a0c8df commit c0353c7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion builtin/hash-object.c
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ static void hash_stdin_paths(const char *type, int no_filters, unsigned flags,
{
struct strbuf buf = STRBUF_INIT, nbuf = STRBUF_INIT;

while (strbuf_getline_lf(&buf, stdin) != EOF) {
while (strbuf_getline(&buf, stdin) != EOF) {
if (buf.buf[0] == '"') {
strbuf_reset(&nbuf);
if (unquote_c_style(&nbuf, buf.buf, NULL))
Expand Down

0 comments on commit c0353c7

Please sign in to comment.