changeset 6470 | ac0bcd951c2c |
parent 6212 | e75aab656f46 |
child 7080 | a6477aa893b8 |
--- a/tests/md5sum.py Fri Apr 04 22:41:17 2008 +0200 +++ b/tests/md5sum.py Fri Apr 04 22:36:40 2008 +0200 @@ -7,7 +7,11 @@ # GPL-compatible. import sys -import md5 + +try: + from hashlib import md5 +except ImportError: + from md5 import md5 for filename in sys.argv[1:]: try: @@ -16,7 +20,7 @@ sys.stderr.write('%s: Can\'t open: %s\n' % (filename, msg)) sys.exit(1) - m = md5.new() + m = md5() try: while 1: data = fp.read(8192)