summaryrefslogtreecommitdiff
path: root/remote.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2015-10-28 13:27:33 -0700
committerJunio C Hamano <gitster@pobox.com>2016-01-15 10:34:42 -0800
commit18814d0e2d7d5924a799bcf0cae3a0aaba569613 (patch)
treeca686da2117dd71fd9d0b548db76e3d27a701e4a /remote.c
parent1f3b1efd18a935fed41431132c67cde5a94833ae (diff)
downloadgit-18814d0e2d7d5924a799bcf0cae3a0aaba569613.tar.gz
remote.c: read $GIT_DIR/remotes/* with strbuf_getline()
These files can be edited with a DOS editor, leaving CR at the end of the line if read with strbuf_getline(). Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'remote.c')
-rw-r--r--remote.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/remote.c b/remote.c
index f19569385e..7d61dabebb 100644
--- a/remote.c
+++ b/remote.c
@@ -256,7 +256,7 @@ static void read_remotes_file(struct remote *remote)
if (!f)
return;
remote->origin = REMOTE_REMOTES;
- while (strbuf_getline_lf(&buf, f) != EOF) {
+ while (strbuf_getline(&buf, f) != EOF) {
const char *v;
strbuf_rtrim(&buf);