diff options
author | CYBERDEViL | 2020-12-20 16:56:42 +0100 |
---|---|---|
committer | bartus | 2020-12-20 17:01:32 +0100 |
commit | b065223d5f58ae66650e538681dbfd66f58b4249 (patch) | |
tree | 96363fa447db4d39723c1dadf4265700cd15b733 /python3.9_2.patch | |
parent | d3e7a5221df9eb686846292a5ca25815763be689 (diff) | |
download | aur-b065223d5f58ae66650e538681dbfd66f58b4249.tar.gz |
Build fix for newer dependencies.
Signed-off-by: bartus <szczepaniak.bartek+github@gmail.com>
fix #1
Diffstat (limited to 'python3.9_2.patch')
-rw-r--r-- | python3.9_2.patch | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/python3.9_2.patch b/python3.9_2.patch new file mode 100644 index 000000000000..a1de7b401485 --- /dev/null +++ b/python3.9_2.patch @@ -0,0 +1,23 @@ +diff --git a/source/blender/python/generic/bpy_threads.c b/source/blender/python/generic/bpy_threads.c +index 5507aa73183..4807c1f5071 100644 +--- a/source/blender/python/generic/bpy_threads.c ++++ b/source/blender/python/generic/bpy_threads.c +@@ -29,14 +29,11 @@ + /* analogue of PyEval_SaveThread() */ + BPy_ThreadStatePtr BPY_thread_save(void) + { +- PyThreadState *tstate = PyThreadState_Swap(NULL); +- /* note: tstate can be NULL when quitting Blender */ +- +- if (tstate && PyEval_ThreadsInitialized()) { +- PyEval_ReleaseLock(); ++ /* The thread-state can be NULL when quitting Blender. */ ++ if (_PyThreadState_UncheckedGet()) { ++ return (BPy_ThreadStatePtr)PyEval_SaveThread(); + } +- +- return (BPy_ThreadStatePtr)tstate; ++ return NULL; + } + + /* analogue of PyEval_RestoreThread() */ |