py api integration: __import__(... , level=0)
authorCampbell Barton <ideasman42@gmail.com>
Mon, 21 May 2012 07:00:23 +0000 (07:00 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Mon, 21 May 2012 07:00:23 +0000 (07:00 +0000)
  default changed to work with python3.3

source/blender/python/generic/bpy_internal_import.c

index ad97d741f9be23c6cf8c1d01760eb3161b4d191a..5999040a2ab371e44d55cfcc1c114743d4dfee0d 100644 (file)
@@ -226,7 +226,7 @@ static PyObject *blender_import(PyObject *UNUSED(self), PyObject *args, PyObject
        char *name;
        int found = 0;
        PyObject *globals = NULL, *locals = NULL, *fromlist = NULL;
-       int level = -1; /* relative imports */
+       int level = 0; /* relative imports */
        
        PyObject *newmodule;
        //PyObject_Print(args, stderr, 0);