branch | stable |
changeset 35803 | 3ad3aaeb1134 |
parent 35802 | bbc07357b567 |
child 35804 | 2d3e486d09d0 |
--- a/mercurial/streamclone.py Wed Jan 24 21:37:48 2018 +0100 +++ b/mercurial/streamclone.py Wed Jan 24 21:44:31 2018 +0100 @@ -594,12 +594,12 @@ for vfs in vfsmap.values()) with nested(*ctxs): for i in range(filecount): - src = fp.read(1) + src = util.readexactly(fp, 1) vfs = vfsmap[src] namelen = util.uvarintdecodestream(fp) datalen = util.uvarintdecodestream(fp) - name = fp.read(namelen) + name = util.readexactly(fp, namelen) if repo.ui.debugflag: repo.ui.debug('adding [%s] %s (%s)\n' %