from portage.output import EOutput
from portage.util import writemsg
-def digestcheck(myfiles, mysettings, strict=False, justmanifest=None):
+def digestcheck(myfiles, mysettings, strict=False, justmanifest=None, mf=None):
"""
Verifies checksums. Assumes all files have been downloaded.
@rtype: int
return 0
else:
return 1
- mf = Manifest(pkgdir, mysettings["DISTDIR"])
+ if mf is None:
+ mf = Manifest(pkgdir, mysettings["DISTDIR"])
manifest_empty = True
for d in mf.fhashdict.values():
if d:
# See above comment about fetching only when needed
if tree == 'porttree' and \
- not digestcheck(checkme, mysettings, "strict" in features):
+ not digestcheck(checkme, mysettings, "strict" in features, mf=mf):
return 1
if mydo == "fetch":