Mercurial > cpython-lru_cache-weakref
diff Modules/socketmodule.c @ 59998:d11fbc796499 legacy-trunk
Backported PyCapsule from 3.1, and converted most uses of
CObject to PyCapsule.
| author | Larry Hastings <larry@hastings.org> |
|---|---|
| date | Thu, 25 Mar 2010 00:54:54 +0000 |
| parents | 435fa215d33f |
| children | 1df34fa491bd |
line wrap: on
line diff
--- a/Modules/socketmodule.c Thu Mar 25 00:51:58 2010 +0000 +++ b/Modules/socketmodule.c Thu Mar 25 00:54:54 2010 +0000 @@ -4496,7 +4496,7 @@ /* Export C API */ if (PyModule_AddObject(m, PySocket_CAPI_NAME, - PyCObject_FromVoidPtr((void *)&PySocketModuleAPI, NULL) + PyCapsule_New(&PySocketModuleAPI, PySocket_CAPSULE_NAME, NULL) ) != 0) return;
