summaryrefslogtreecommitdiffstats
path: root/Modules/socketmodule.c
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/socketmodule.c')
-rw-r--r--Modules/socketmodule.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/socketmodule.c b/Modules/socketmodule.c
index fbd0239..d44a691 100644
--- a/Modules/socketmodule.c
+++ b/Modules/socketmodule.c
@@ -4496,7 +4496,7 @@ init_socket(void)
/* Export C API */
if (PyModule_AddObject(m, PySocket_CAPI_NAME,
- PyCObject_FromVoidPtr((void *)&PySocketModuleAPI, NULL)
+ PyCapsule_New(&PySocketModuleAPI, PySocket_CAPSULE_NAME, NULL)
) != 0)
return;