aboutsummaryrefslogtreecommitdiff
path: root/revision.c
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2016-08-09 23:47:31 +0000
committerJunio C Hamano <gitster@pobox.com>2016-08-10 09:27:26 -0700
commitb36045c1dc43e36f6fb84b041b59317b7f02b58c (patch)
treefa2d7692447f207f7431c3f2740078afda7460c8 /revision.c
parent00f27feb6afaa9e5f91a0852a5a20c041ba0a421 (diff)
downloadgit-b36045c1dc43e36f6fb84b041b59317b7f02b58c.tar.gz
git-b36045c1dc43e36f6fb84b041b59317b7f02b58c.tar.xz
http-backend: buffer headers before sending
Avoid waking up the readers for unnecessary context switches for each line of header data being written, as all the headers are written in short succession. It is unlikely any HTTP/1.x server would want to read a CGI response one-line-at-a-time and trickle each to the client. Instead, I'd expect HTTP servers want to minimize syscall and TCP/IP framing overhead by trying to send all of its response headers in a single syscall or even combining the headers and first chunk of the body with MSG_MORE or writev. Verified by strace-ing response parsing on the CGI side. Signed-off-by: Eric Wong <e@80x24.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'revision.c')
0 files changed, 0 insertions, 0 deletions