Fix assert in debug mode when built as Python module

Ref: !121500
This commit is contained in:
Ahmed Essam
2024-05-06 22:33:44 +03:00
committed by Campbell Barton
parent 03cd8b359b
commit 0ca1386426

View File

@@ -558,7 +558,9 @@ void BPY_python_start(bContext *C, int argc, const char **argv)
void BPY_python_end(const bool do_python_exit)
{
#ifndef WITH_PYTHON_MODULE
BLI_assert_msg(Py_IsInitialized() != 0, "Python must be initialized");
#endif
PyGILState_STATE gilstate;