summaryrefslogtreecommitdiffstats
path: root/pym
diff options
context:
space:
mode:
Diffstat (limited to 'pym')
-rw-r--r--pym/portage_manifest.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/pym/portage_manifest.py b/pym/portage_manifest.py
index 6645963dd..c0f8bef9d 100644
--- a/pym/portage_manifest.py
+++ b/pym/portage_manifest.py
@@ -344,8 +344,15 @@ class Manifest(object):
except FileNotFound:
pass
+ def checkIntegrity(self):
+ for t in self.fhashdict:
+ for f in self.fhashdict[t]:
+ if portage_const.MANIFEST2_REQUIRED_HASH not in self.fhashdict[t][f]:
+ raise MissingParameter("Missing %s checksum: %s %s" % (portage_const.MANIFEST2_REQUIRED_HASH, t, f))
+
def write(self, sign=False, force=False):
""" Write Manifest instance to disk, optionally signing it """
+ self.checkIntegrity()
try:
if self.compat:
self._writeDigests()