diff options
Diffstat (limited to 'contrib/testgen/gen_base58_test_vectors.py')
-rwxr-xr-x | contrib/testgen/gen_base58_test_vectors.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/contrib/testgen/gen_base58_test_vectors.py b/contrib/testgen/gen_base58_test_vectors.py index 1813436953..86366eb8e3 100755 --- a/contrib/testgen/gen_base58_test_vectors.py +++ b/contrib/testgen/gen_base58_test_vectors.py @@ -1,4 +1,7 @@ #!/usr/bin/env python +# Copyright (c) 2012-2016 The Bitcoin Core developers +# Distributed under the MIT software license, see the accompanying +# file COPYING or http://www.opensource.org/licenses/mit-license.php. ''' Generate valid and invalid base58 address and private key test vectors. @@ -10,7 +13,7 @@ Usage: # Released under MIT License import os from itertools import islice -from base58 import b58encode, b58decode, b58encode_chk, b58decode_chk, b58chars +from base58 import b58encode_chk, b58decode_chk, b58chars import random from binascii import b2a_hex @@ -42,7 +45,6 @@ def is_valid(v): result = b58decode_chk(v) if result is None: return False - valid = False for template in templates: prefix = str(bytearray(template[0])) suffix = str(bytearray(template[2])) |