Content-Length: 255973 | pFad | https://github.com/python/cpython/commit/df36d7d385a9cdf22d1f2e28fe2a1e024fe6b902

DE Update Lib/hmac.py · python/cpython@df36d7d · GitHub
Skip to content

Commit df36d7d

Browse files
authored
Update Lib/hmac.py
1 parent f93e1ba commit df36d7d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Lib/hmac.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,7 @@ def digest(key, msg, digest):
242242
try:
243243
return _hashopenssl.hmac_digest(key, msg, digest)
244244
except OverflowError as exc:
245-
if not isinstance(digest, str):
245+
if _hmac is None or not isinstance(digest, str):
246246
# Without re-raising now, slow HMAC will be used as
247247
# HACL* HMAC only identifies digests by their name.
248248
raise exc

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: https://github.com/python/cpython/commit/df36d7d385a9cdf22d1f2e28fe2a1e024fe6b902

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy