bugfix [#24087] Blender can not install add-ons unless running with root priviledges

now addon path is created using the same path functions and selecting where to save the startup.blend

also made some minor changes to path handling funcs.
This commit is contained in:
2010-10-03 20:00:22 +00:00
parent 3e3e10668e
commit ab8aa13b82
10 changed files with 94 additions and 33 deletions

View File

@@ -248,8 +248,8 @@ void BPY_start_python( int argc, char **argv )
//PyObject *m = PyImport_AddModule("__builtin__");
//PyObject *d = PyModule_GetDict(m);
PyObject *d = PyEval_GetBuiltins( );
PyDict_SetItemString(d, "reload", item=PyCFunction_New(bpy_reload_meth, NULL)); Py_DECREF(item);
PyDict_SetItemString(d, "__import__", item=PyCFunction_New(bpy_import_meth, NULL)); Py_DECREF(item);
PyDict_SetItemString(d, "reload", item=PyCFunction_New(&bpy_reload_meth, NULL)); Py_DECREF(item);
PyDict_SetItemString(d, "__import__", item=PyCFunction_New(&bpy_import_meth, NULL)); Py_DECREF(item);
}
pyrna_alloc_types();