mirror of
https://github.com/python/cpython.git
synced 2025-08-04 17:08:35 +00:00
[3.13] gh-132674: fix _hashopenssl.c
compiler warnings on free-threaded build (GH-132675) (#132677)
gh-132674: fix `_hashopenssl.c` compiler warnings on free-threaded build (GH-132675)
(cherry picked from commit 2df0f88047
)
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
This commit is contained in:
parent
bfba11ad11
commit
b78728210c
1 changed files with 2 additions and 2 deletions
|
@ -410,7 +410,7 @@ py_digest_by_name(PyObject *module, const char *name, enum Py_hash_type py_ht)
|
|||
digest = PY_EVP_MD_fetch(entry->ossl_name, NULL);
|
||||
#ifdef Py_GIL_DISABLED
|
||||
// exchange just in case another thread did same thing at same time
|
||||
other_digest = _Py_atomic_exchange_ptr(&entry->evp, digest);
|
||||
other_digest = _Py_atomic_exchange_ptr(&entry->evp, (void *)digest);
|
||||
#else
|
||||
entry->evp = digest;
|
||||
#endif
|
||||
|
@ -422,7 +422,7 @@ py_digest_by_name(PyObject *module, const char *name, enum Py_hash_type py_ht)
|
|||
digest = PY_EVP_MD_fetch(entry->ossl_name, "-fips");
|
||||
#ifdef Py_GIL_DISABLED
|
||||
// exchange just in case another thread did same thing at same time
|
||||
other_digest = _Py_atomic_exchange_ptr(&entry->evp_nosecurity, digest);
|
||||
other_digest = _Py_atomic_exchange_ptr(&entry->evp_nosecurity, (void *)digest);
|
||||
#else
|
||||
entry->evp_nosecurity = digest;
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue