comparison mercurial/localrepo.py @ 18422:f009804e2a43

validate: check for spurious incoming filelog entries Accepting those will lead to "mild corruption", correctly reported as an error by hg verify, but often not a problem in practice. Enabled when server.validate is switched on.
author Sune Foldager <cryo@cyanite.org>
date Tue, 11 Dec 2012 20:13:21 +0100
parents ecf4f79cc600
children 4d9f7dd2ac82
comparison
equal deleted inserted replaced
18421:e8982483f9dc 18422:f009804e2a43
2309 needs = needfiles[f] 2309 needs = needfiles[f]
2310 for new in xrange(o, len(fl)): 2310 for new in xrange(o, len(fl)):
2311 n = fl.node(new) 2311 n = fl.node(new)
2312 if n in needs: 2312 if n in needs:
2313 needs.remove(n) 2313 needs.remove(n)
2314 else:
2315 raise util.Abort(
2316 _("received spurious file revlog entry"))
2314 if not needs: 2317 if not needs:
2315 del needfiles[f] 2318 del needfiles[f]
2316 self.ui.progress(_('files'), None) 2319 self.ui.progress(_('files'), None)
2317 2320
2318 for f, needs in needfiles.iteritems(): 2321 for f, needs in needfiles.iteritems():