From 7efac2b0b09d9e76d9fc573ec7936a1c6440c067 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 10 Nov 2018 10:55:04 +1100 Subject: PyAPI: add imports arg to BPY_execute_string Allows for avoiding `__import__` in expressions, was already supported for BPY_execute_string_as_* API calls. --- source/blender/freestyle/intern/system/PythonInterpreter.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/blender/freestyle') diff --git a/source/blender/freestyle/intern/system/PythonInterpreter.h b/source/blender/freestyle/intern/system/PythonInterpreter.h index 4f5e94ef7a0..cb49e7718a0 100644 --- a/source/blender/freestyle/intern/system/PythonInterpreter.h +++ b/source/blender/freestyle/intern/system/PythonInterpreter.h @@ -112,7 +112,7 @@ public: BKE_reports_clear(reports); - if (!BPY_execute_string(_context, str.c_str())) { + if (!BPY_execute_string(_context, NULL, str.c_str())) { BPy_errors_to_report(reports); cerr << "\nError executing Python script from PythonInterpreter::interpretString" << endl; cerr << "Name: " << name << endl; -- cgit v1.2.3