equal
deleted
inserted
replaced
1870 ifh.write(entry) |
1870 ifh.write(entry) |
1871 ifh.write(data[0]) |
1871 ifh.write(data[0]) |
1872 ifh.write(data[1]) |
1872 ifh.write(data[1]) |
1873 self.checkinlinesize(transaction, ifh) |
1873 self.checkinlinesize(transaction, ifh) |
1874 |
1874 |
1875 def addgroup(self, cg, linkmapper, transaction, addrevisioncb=None): |
1875 def addgroup(self, deltas, transaction, addrevisioncb=None): |
1876 """ |
1876 """ |
1877 add a delta group |
1877 add a delta group |
1878 |
1878 |
1879 given a set of deltas, add them to the revision log. the |
1879 given a set of deltas, add them to the revision log. the |
1880 first delta is against its parent, which should be in our |
1880 first delta is against its parent, which should be in our |
1903 if dfh: |
1903 if dfh: |
1904 dfh.flush() |
1904 dfh.flush() |
1905 ifh.flush() |
1905 ifh.flush() |
1906 try: |
1906 try: |
1907 # loop through our set of deltas |
1907 # loop through our set of deltas |
1908 chain = None |
1908 for data in deltas: |
1909 for chunkdata in iter(lambda: cg.deltachunk(chain), {}): |
1909 node, p1, p2, link, deltabase, delta, flags = data |
1910 node = chunkdata['node'] |
1910 flags = flags or REVIDX_DEFAULT_FLAGS |
1911 p1 = chunkdata['p1'] |
|
1912 p2 = chunkdata['p2'] |
|
1913 cs = chunkdata['cs'] |
|
1914 deltabase = chunkdata['deltabase'] |
|
1915 delta = chunkdata['delta'] |
|
1916 flags = chunkdata['flags'] or REVIDX_DEFAULT_FLAGS |
|
1917 |
1911 |
1918 nodes.append(node) |
1912 nodes.append(node) |
1919 chain = node |
1913 |
1920 |
|
1921 link = linkmapper(cs) |
|
1922 if node in self.nodemap: |
1914 if node in self.nodemap: |
1923 # this can happen if two branches make the same change |
1915 # this can happen if two branches make the same change |
1924 continue |
1916 continue |
1925 |
1917 |
1926 for p in (p1, p2): |
1918 for p in (p1, p2): |