https://github.com/python/cpython/commit/1d4e3e0585c1051ec182666668137fbb0fc1a4d2
commit: 1d4e3e0585c1051ec182666668137fbb0fc1a4d2
branch: main
author: Victor Stinner <[email protected]>
committer: vstinner <[email protected]>
date: 2024-10-02T13:58:47Z
summary:

gh-111178: Fix locale_free() signature (#124896)

files:
M Modules/_localemodule.c

diff --git a/Modules/_localemodule.c b/Modules/_localemodule.c
index de7395b610e133..9452df492bb23b 100644
--- a/Modules/_localemodule.c
+++ b/Modules/_localemodule.c
@@ -881,9 +881,9 @@ locale_clear(PyObject *module)
 }
 
 static void
-locale_free(PyObject *module)
+locale_free(void *module)
 {
-    locale_clear(module);
+    locale_clear((PyObject*)module);
 }
 
 static struct PyModuleDef _localemodule = {
@@ -895,7 +895,7 @@ static struct PyModuleDef _localemodule = {
     _locale_slots,
     locale_traverse,
     locale_clear,
-    (freefunc)locale_free,
+    locale_free,
 };
 
 PyMODINIT_FUNC

_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-checkins.python.org/
Member address: [email protected]

Reply via email to