From a5a73402909462ae8b0aa0bd73a81dd6eab45d71 Mon Sep 17 00:00:00 2001 From: str4d Date: Wed, 26 May 2021 17:50:50 +0100 Subject: [PATCH] Remove unnecessary txin parameters These were leftover from an earlier version of the PR. Co-authored-by: ying tong --- zip_0244.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/zip_0244.py b/zip_0244.py index 6f96b59..a9d6f68 100644 --- a/zip_0244.py +++ b/zip_0244.py @@ -199,21 +199,21 @@ def transparent_sig_digest(tx, nHashType, txin): digest = blake2b(digest_size=32, person=b'ZTxIdTranspaHash') - digest.update(prevouts_sig_digest(tx, nHashType, txin)) - digest.update(sequence_sig_digest(tx, nHashType, txin)) + digest.update(prevouts_sig_digest(tx, nHashType)) + digest.update(sequence_sig_digest(tx, nHashType)) digest.update(outputs_sig_digest(tx, nHashType, txin)) digest.update(txin_sig_digest(tx, txin)) return digest.digest() -def prevouts_sig_digest(tx, nHashType, txin): +def prevouts_sig_digest(tx, nHashType): # If the SIGHASH_ANYONECANPAY flag is not set: if not (nHashType & SIGHASH_ANYONECANPAY): return getHashPrevouts(tx, b'ZTxIdPrevoutHash') else: return blake2b(digest_size=32, person=b'ZTxIdPrevoutHash').digest() -def sequence_sig_digest(tx, nHashType, txin): +def sequence_sig_digest(tx, nHashType): # if the SIGHASH_ANYONECANPAY flag is not set, and the sighash type is neither # SIGHASH_SINGLE nor SIGHASH_NONE: if (