Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/python/generic/py_capi_utils.c')
-rw-r--r--source/blender/python/generic/py_capi_utils.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/source/blender/python/generic/py_capi_utils.c b/source/blender/python/generic/py_capi_utils.c
index 1bccc8a24c4..e658532db24 100644
--- a/source/blender/python/generic/py_capi_utils.c
+++ b/source/blender/python/generic/py_capi_utils.c
@@ -184,6 +184,15 @@ void PyC_FileAndNum(const char **filename, int *lineno)
}
}
+void PyC_FileAndNum_Safe(const char **filename, int *lineno)
+{
+ if(!PYC_INTERPRETER_ACTIVE) {
+ return;
+ }
+
+ PyC_FileAndNum(filename, lineno);
+}
+
/* Would be nice if python had this built in */
PyObject *PyC_Object_GetAttrStringArgs(PyObject *o, Py_ssize_t n, ...)
{