Gui: Fix crash in ~PythonBaseWorkbench with Python 3.12

This commit is contained in:
wmayer
2025-04-04 20:04:29 +02:00
committed by Ladislav Michl
parent f5bfc10c81
commit a6234f2ee3

View File

@@ -1057,6 +1057,7 @@ PythonBaseWorkbench::~PythonBaseWorkbench()
delete _toolBar;
delete _commandBar;
if (_workbenchPy) {
Base::PyGILStateLocker lock;
_workbenchPy->setInvalid();
_workbenchPy->DecRef();
}