From: Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> Date: Fri, 18 Apr 2025 12:17:36 +0000 (+0200) Subject: [3.13] gh-132674: fix `_hashopenssl.c` compiler warnings on free-threaded build ... X-Git-Tag: v3.13.4~256 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=b78728210c716121c76856393bc0cc61cd2039d4;p=thirdparty%2FPython%2Fcpython.git [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 2df0f8804701cc17674e5b4e90499e9fac71d0e1) Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com> --- diff --git a/Modules/_hashopenssl.c b/Modules/_hashopenssl.c index d569b5048669..b2a5754e7740 100644 --- a/Modules/_hashopenssl.c +++ b/Modules/_hashopenssl.c @@ -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