[PATCH v4 16/21] transport-helper: read helper response with strbuf_getline()
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jan 14, 2016, 23:58 UTC
- Message-ID
- <1452815916-6447-17-git-send-email-gitster@pobox.com>
- In-Reply-To
- <1452815916-6447-1-git-send-email-gitster@pobox.com>
Our implementation of helpers never use CRLF line endings, and they do not depend on the ability to place a CR as payload at the end of the line, so this is essentially a no-op for in-tree users. However, this allows third-party implementation of helpers to give us their line with CRLF line ending (they cannot expect us to feed CRLF to them, though).
Signed-off-by: Junio C Hamano <gitster@pobox.com> --- transport-helper.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/transport-helper.c b/transport-helper.c index e45d88f..a6bff8b 100644 --- a/transport-helper.c +++ b/transport-helper.c @@ -54,7 +54,7 @@ static int recvline_fh(FILE *helper, struct strbuf *buffer, const char *name) strbuf_reset(buffer); if (debug) fprintf(stderr, "Debug: Remote helper: Waiting...\n"); - if (strbuf_getline_lf(buffer, helper) == EOF) { + if (strbuf_getline(buffer, helper) == EOF) { if (debug) fprintf(stderr, "Debug: Remote helper quit.\n"); return 1;
-- 2.7.0-250-ge1b5ba3