remote-curl: refactor reading into rpc_state's buf
authorJonathan Tan <jonathantanmy@google.com>
Thu, 21 Feb 2019 20:24:40 +0000 (12:24 -0800)
committerJunio C Hamano <gitster@pobox.com>
Fri, 22 Feb 2019 22:27:31 +0000 (14:27 -0800)
Currently, whenever remote-curl reads pkt-lines from its response file
descriptor, only the payload is written to its buf, not the 4 characters
denoting the length. A future patch will require the ability to also
write those 4 characters, so in preparation for that, refactor this read
into its own function.

Signed-off-by: Jonathan Tan <jonathantanmy@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
No differences found