948 PyMODINIT_FUNC
949 initradix(void)
950 {
951 PyObject *m, *d;
952 #if defined(_MSC_VER)
953 WSADATA winsock_data;
954 int r;
955 char errbuf[256];
956
957 r = WSAStartup(0x0202, &winsock_data);
958 switch (r) {
959 case 0:
960 Py_AtExit(cleanupradix);
961 break;
962 case WSASYSNOTREADY:
963 PyErr_SetString(PyExc_ImportError, "Winsock error: "
964 "network subsystem not ready");
965 return;
966 case WSAEINVAL:
967 case WSAVERNOTSUPPORTED:
968 PyErr_SetString(PyExc_ImportError, "Winsock error: "
969 "required winsock version 2.2 not supported");
970 return;
971 default:
972 snprintf(errbuf, sizeof(errbuf), "Winsock error: code %d", r);
973 PyErr_SetString(PyExc_ImportError, errbuf);
974 return;
975 }
976 #endif
977
978 if (PyType_Ready(&Radix_Type) < 0)
when PyType_Ready() succeeds
taking False path
979 return;
980 if (PyType_Ready(&RadixNode_Type) < 0)
when PyType_Ready() succeeds
taking False path
981 return;
982 m = Py_InitModule3("radix", radix_methods, module_doc);
when Py_InitModule4_64() succeeds
983
984 /* Stash the callable constructor for use in Radix.__reduce__ */
985 d = PyModule_GetDict(m);
986 radix_constructor = PyDict_GetItemString(d, "Radix");
when PyDict_GetItemString() succeeds
borrowed reference returned by PyDict_GetItemString() allocated at: radix_constructor = PyDict_GetItemString(d, "Radix");
ob_refcnt is now refs: 0 + N where N >= 1
'*radix_constructor' is now referenced by 1 non-stack value(s): radix_constructor
987
988 PyModule_AddStringConstant(m, "__version__", "0.4");
when PyModule_AddStringConstant() succeeds
989 }
ob_refcnt of '*radix_constructor' is 1 too low
was expecting final ob_refcnt to be N + 1 (for some unknown N)
due to object being referenced by: radix_constructor
but final ob_refcnt is N + 0
found 3 similar trace(s) to this