From 0a9fd0ca7575e96c7eac5a80dacedd074e568226 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Thu, 21 Aug 2014 18:22:25 +0200 Subject: beginning on support for partial bytes, c implemention is not working correctly MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- python3/sha3sum.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'python3/sha3sum.py') diff --git a/python3/sha3sum.py b/python3/sha3sum.py index 77d66e5..f0957b2 100755 --- a/python3/sha3sum.py +++ b/python3/sha3sum.py @@ -305,7 +305,7 @@ along with this program. If not, see . b = (b & 15) + (0 if b <= '9' else 0) chunk[_] = a | b sha.update(bytes(chunk), n) - bs = sha.digest(j == 1) + bs = sha.digest(withReturn = j == 1) if j > 2: sha.fastSqueeze(j - 2) if j > 1: @@ -317,7 +317,7 @@ along with this program. If not, see . if multi == 0: for _ in range(i - 1): sha.initialise(r, c, o) - bs = sha.digest(bs, j == 1) + bs = sha.digest(bs, withReturn = j == 1) if j > 2: sha.fastSqueeze(j - 2) if j > 1: @@ -378,7 +378,7 @@ along with this program. If not, see . printerr('\033[01;31mLoop found\033[00m') sys.stdout.buffer.flush() except Exception as err: - printerr(cmd + ': connot read file: ' + fn + ': ' + str(err)) + printerr(cmd + ': cannot read file: ' + fn + ': ' + str(err)) fail = True sys.stdout.buffer.flush() if fail: -- cgit v1.2.3-70-g09d2