Skip to content

Commit

Permalink
Fix broken cPython: md5.digest() is not supposed to raise exceptions …
Browse files Browse the repository at this point in the history
…#2213
  • Loading branch information
ita1024 committed Dec 6, 2018
1 parent 753b153 commit 1c7be35
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion waflib/Utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,14 @@ class TimeoutExpired(Exception):
try:
from hashlib import sha1 as md5
except ImportError:
# never fail to enable fixes from another module
# never fail to enable potential fixes from another module
pass
else:
try:
md5().digest()
except ValueError:
# Fips? #2213
from hashlib import sha1 as md5

try:
import threading
Expand Down

0 comments on commit 1c7be35

Please sign in to comment.