diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-10-30 02:59:39 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-10-30 02:59:39 +0400 |
commit | ced06081b8ef2c9cefd0ed61461c54d5393ca23d (patch) | |
tree | cf3b5fd656c58bce003bc9958d3f49621f47dc2a /source/blender/python/intern/bpy_operator.c | |
parent | 719c941c58f8b4acaced83c7521a6746fdd0841f (diff) |
use PyImport_ExtendInittab for py module initialization rather then adding to sys.modules directly, no functional change.
Diffstat (limited to 'source/blender/python/intern/bpy_operator.c')
-rw-r--r-- | source/blender/python/intern/bpy_operator.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/source/blender/python/intern/bpy_operator.c b/source/blender/python/intern/bpy_operator.c index 3ffa78dab70..1cf99218bf6 100644 --- a/source/blender/python/intern/bpy_operator.c +++ b/source/blender/python/intern/bpy_operator.c @@ -313,14 +313,8 @@ static struct PyModuleDef bpy_ops_module = { PyObject *BPY_operator_module(void) { PyObject *submodule; - - submodule= PyModule_Create(&bpy_ops_module); - PyDict_SetItemString(PyImport_GetModuleDict(), bpy_ops_module.m_name, submodule); - /* INCREF since its its assumed that all these functions return the - * module with a new ref like PyDict_New, since they are passed to - * PyModule_AddObject which steals a ref */ - Py_INCREF(submodule); + submodule= PyModule_Create(&bpy_ops_module); return submodule; } |