From 6b87bc371b91917980884d6dd20e39d3cda47fc7 Mon Sep 17 00:00:00 2001 From: Helmut Grohne Date: Wed, 29 Dec 2021 15:36:12 +0100 Subject: DecompressedHash: also gain a name property for consistency --- importpkg.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'importpkg.py') diff --git a/importpkg.py b/importpkg.py index 6988c1d..6772c4d 100755 --- a/importpkg.py +++ b/importpkg.py @@ -25,9 +25,9 @@ def sha512_nontrivial(): return HashBlacklistContent(hashlib.sha512(), boring_content) def gziphash(): - hashobj = DecompressedHash(GzipDecompressor(), hashlib.sha512()) + hashobj = hashlib.sha512() + hashobj = DecompressedHash(GzipDecompressor(), hashobj, "gzip_sha512") hashobj = SuppressingHash(hashobj, (ValueError, zlib.error)) - hashobj.name = "gzip_sha512" return HashBlacklistContent(hashobj, boring_content) def pnghash(): -- cgit v1.2.3