diff mercurial/bundlerepo.py @ 18417:610706715778

bundlerepo: use revlog._checkhash The error message will mention datafile instead of indexfile.
author Mads Kiilerich <madski@unity3d.com>
date Wed, 16 Jan 2013 20:41:41 +0100
parents 87f370c5fef5
children e72126135252
line wrap: on
line diff
--- a/mercurial/bundlerepo.py	Wed Jan 16 20:41:41 2013 +0100
+++ b/mercurial/bundlerepo.py	Wed Jan 16 20:41:41 2013 +0100
@@ -130,11 +130,7 @@
             delta = self._chunk(chain.pop())
             text = mdiff.patches(text, [delta])
 
-        p1, p2 = self.parents(node)
-        if node != revlog.hash(text, p1, p2):
-            raise error.RevlogError(_("integrity check failed on %s:%d")
-                                     % (self.datafile, rev))
-
+        self._checkhash(text, node, rev)
         self._cache = (node, rev, text)
         return text