changeset 12336 | 9d234f7d8a77 |
parent 12335 | e21fe9c5fb25 |
child 12347 | 6277a9469dff |
--- a/mercurial/changegroup.py Sun Sep 19 12:51:54 2010 -0500 +++ b/mercurial/changegroup.py Sun Sep 19 13:12:45 2010 -0500 @@ -163,6 +163,15 @@ % (len(d), l)) return d + def parsechunk(self): + l = self.chunklength() + if not l: + return {} + h = self.read(80) + node, p1, p2, cs = struct.unpack("20s20s20s20s", h) + data = self.read(l - 80) + return dict(node=node, p1=p1, p2=p2, cs=cs, data=data) + class headerlessfixup(object): def __init__(self, fh, h): self._h = h