summaryrefslogtreecommitdiffstats
path: root/pym/portage/checksum.py
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2008-07-02 07:50:54 +0000
committerZac Medico <zmedico@gentoo.org>2008-07-02 07:50:54 +0000
commit2ea11722ca25a22659685e4b8020a9c52b933b6a (patch)
tree4f1f7c91cea611f01ba396ead5dd200e8915a587 /pym/portage/checksum.py
parenta11eefe66802e21b8f042d0a50de9d4b24ffa57f (diff)
downloadportage-2ea11722ca25a22659685e4b8020a9c52b933b6a.tar.gz
portage-2ea11722ca25a22659685e4b8020a9c52b933b6a.tar.bz2
portage-2ea11722ca25a22659685e4b8020a9c52b933b6a.zip
Py3k compatibility patch by Ali Polatel <hawking@g.o>.
Don't use the format raise Exception, "string" svn path=/main/trunk/; revision=10890
Diffstat (limited to 'pym/portage/checksum.py')
-rw-r--r--pym/portage/checksum.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/pym/portage/checksum.py b/pym/portage/checksum.py
index 52ce59148..8364d26ed 100644
--- a/pym/portage/checksum.py
+++ b/pym/portage/checksum.py
@@ -186,7 +186,10 @@ def verify_all(filename, mydict, calc_prelink=0, strict=0):
myhash = perform_checksum(filename, x, calc_prelink=calc_prelink)[0]
if mydict[x] != myhash:
if strict:
- raise portage.exception.DigestException, "Failed to verify '$(file)s' on checksum type '%(type)s'" % {"file":filename, "type":x}
+ raise portage.exception.DigestException(
+ ("Failed to verify '$(file)s' on " + \
+ "checksum type '%(type)s'") % \
+ {"file" : filename, "type" : x})
else:
file_is_ok = False
reason = (("Failed on %s verification" % x), myhash,mydict[x])