diff --git a/src/gpgme.c b/src/gpgme.c index 7b80c95..8bfe3e9 100644 --- a/src/gpgme.c +++ b/src/gpgme.c @@ -46,7 +46,7 @@ create_module(void) #define INIT_TYPE(type) \ if (!Py_TYPE(&type)) \ - Py_TYPE(&type) = &PyType_Type; \ + Py_SET_TYPE(&type, &PyType_Type); \ if (!type.tp_alloc) \ type.tp_alloc = PyType_GenericAlloc; \ if (!type.tp_new) \