hash-object: read --stdin-paths with strbuf_getline()
The list of paths could have been written with a DOS editor. Signed-off-by: Junio C Hamano <gitster@pobox.com>
Junio C Hamano committed
Oct 28, 2015 at 13:56 UTC
c0353c78e80434b9385e134c69b54b048c382077
1 file changed
+1
-1
builtin/hash-object.c
+1
-1
@@ -60,7 +60,7 @@ static void hash_stdin_paths(const char *type, int no_filters, unsigned flags,
60
{
61
struct strbuf buf = STRBUF_INIT, nbuf = STRBUF_INIT;
62
63
- while (strbuf_getline_lf(&buf, stdin) != EOF) {
63
+ while (strbuf_getline(&buf, stdin) != EOF) {
64
if (buf.buf[0] == '"') {
65
strbuf_reset(&nbuf);
66
if (unquote_c_style(&nbuf, buf.buf, NULL))