summaryrefslogtreecommitdiff
path: root/t/t4022-diff-rewrite.sh
diff options
context:
space:
mode:
authorLibravatar Nguyễn Thái Ngọc Duy <pclouds@gmail.com>2014-02-06 22:10:39 +0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2014-02-10 10:21:33 -0800
commitff62eca7d1f9716e36550adedc6e8edc35ff9a15 (patch)
tree44d09cf73bccf31083e82d46fa6c279488445325 /t/t4022-diff-rewrite.sh
parentprotocol-capabilities.txt: document no-done (diff)
downloadtgif-ff62eca7d1f9716e36550adedc6e8edc35ff9a15.tar.xz
fetch-pack: fix deepen shallow over smart http with no-done cap
In smart http, upload-pack adds new shallow lines at the beginning of each rpc response. Only shallow lines from the first rpc call are useful. After that they are thrown away. It's designed this way because upload-pack is stateless and has no idea when its shallow lines are helpful or not. So after refs are negotiated with multi_ack_detailed and the server thinks it learned enough, it sends "ACK obj-id ready", terminates the rpc call and waits for the final rpc round. The client sends "done". The server sends another response, which also has shallow lines at the beginning, and the last "ACK obj-id" line. When no-done is active, the last round is cut out, the server sends "ACK obj-id ready" and "ACK obj-id" in the same rpc response. fetch-pack is updated to recognize this and not send "done". However it still tries to consume shallow lines, which are never sent. Update the code, make sure to skip consuming shallow lines when no-done is enabled. Reported-by: Jeff King <peff@peff.net> Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t4022-diff-rewrite.sh')
0 files changed, 0 insertions, 0 deletions