mirror of
https://github.com/python/cpython.git
synced 2026-01-04 14:32:21 +00:00
Dynamically initialize ob_type field, for Windows DLL
This commit is contained in:
parent
c864364395
commit
622f577eac
1 changed files with 2 additions and 1 deletions
|
|
@ -478,7 +478,7 @@ bsddb_getattr(dp, name)
|
|||
}
|
||||
|
||||
static PyTypeObject Bsddbtype = {
|
||||
PyObject_HEAD_INIT(&PyType_Type)
|
||||
PyObject_HEAD_INIT(NULL)
|
||||
0,
|
||||
"bsddb",
|
||||
sizeof(bsddbobject),
|
||||
|
|
@ -667,6 +667,7 @@ void
|
|||
initbsddb() {
|
||||
PyObject *m, *d;
|
||||
|
||||
Bsddbtype.ob_type = &PyType_Type;
|
||||
m = Py_InitModule("bsddb", bsddbmodule_methods);
|
||||
d = PyModule_GetDict(m);
|
||||
BsddbError = PyString_FromString("bsddb.error");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue