client: don't assume server response is of length 20 rc-fix-pack-protocol-v2
authorTay Ray Chuan <rctay89@gmail.com>
Sun, 4 Apr 2010 14:58:31 +0000 (22:58 +0800)
committerTay Ray Chuan <rctay89@gmail.com>
Sat, 10 Apr 2010 03:49:35 +0000 (11:49 +0800)
commit31a832600d8f873640dfc9a8afd4b2c59512abd9
treefe4a53b06208f05965d74b7f565c623505295b86
parent12e1c54f55a71d58335d269b5cc3aefac9bca09e
client: don't assume server response is of length 20

We do not for sure the length; it is safer to use
Protocol.read_pkt_line().

Also, handle HangupException if read_pkt_line() raises it. This happens
when talking to old versions of git-daemon (v1.6.6.1-26-g38a81b4), where
there won't be anything to read.
dulwich/client.py