Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2016-02-04 01:15:58 +0300
committerJunio C Hamano <gitster@pobox.com>2016-02-04 01:15:58 +0300
commit017565525f969c26c43443d998a1283cac843d10 (patch)
tree32d6e0cac811a30e9a709cfb4720310436efc762 /builtin/clone.c
parent07c314d22dc8b0a982e76e7498a3f4d384062491 (diff)
parentf06068c96181f6212e15e32957a3d40c7c7bd43d (diff)
Merge branch 'jc/peace-with-crlf'
Many commands that read files that are expected to contain text that is generated (or can be edited) by the end user to control their behaviour (e.g. "git grep -f <filename>") have been updated to be more tolerant to lines that are terminated with CRLF (they used to treat such a line to contain payload that ends with CR, which is usually not what the users expect). * jc/peace-with-crlf: test-sha1-array: read command stream with strbuf_getline() grep: read -f file with strbuf_getline() send-pack: read list of refs with strbuf_getline() column: read lines with strbuf_getline() cat-file: read batch stream with strbuf_getline() transport-helper: read helper response with strbuf_getline() clone/sha1_file: read info/alternates with strbuf_getline() remote.c: read $GIT_DIR/remotes/* with strbuf_getline() ident.c: read /etc/mailname with strbuf_getline() rev-parse: read parseopt spec with strbuf_getline() revision: read --stdin with strbuf_getline() hash-object: read --stdin-paths with strbuf_getline()
Diffstat (limited to 'builtin/clone.c')
-rw-r--r--builtin/clone.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/clone.c b/builtin/clone.c
index 81e238f738..bcba0805e1 100644
--- a/builtin/clone.c
+++ b/builtin/clone.c
@@ -339,7 +339,7 @@ static void copy_alternates(struct strbuf *src, struct strbuf *dst,
FILE *in = fopen(src->buf, "r");
struct strbuf line = STRBUF_INIT;
- while (strbuf_getline_lf(&line, in) != EOF) {
+ while (strbuf_getline(&line, in) != EOF) {
char *abs_path;
if (!line.len || line.buf[0] == '#')
continue;