Skip to content

Commit da04978

Browse files
committed
Merge branch 'master' into Numpy_2_adaptations
2 parents 77cacf8 + 6a37e04 commit da04978

File tree

2 files changed

+12
-4
lines changed

2 files changed

+12
-4
lines changed

Qitom/python/pythonEngine.cpp

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6770,12 +6770,16 @@ ito::RetVal PythonEngine::pickleSingleParam(QString filename, QSharedPointer<ito
67706770

67716771
PyDict_Clear(exportDict);
67726772
Py_DECREF(exportDict);
6773-
exportDict = NULL;
6774-
6773+
exportDict = nullptr;
6774+
Py_XDECREF(item);
6775+
PyGILState_Release(gstate);
6776+
}
6777+
else
6778+
{
6779+
PyGILState_STATE gstate = PyGILState_Ensure();
6780+
Py_XDECREF(item);
67756781
PyGILState_Release(gstate);
67766782
}
6777-
6778-
Py_XDECREF(item);
67796783

67806784
if (oldState & pyStateIdle)
67816785
{

Qitom/ui/dialogSnapshot.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -549,6 +549,10 @@ void DialogSnapshot::acquisitionEnd()
549549
checkRetval(retval);
550550
break;
551551
}
552+
else if (locker->returnValue != ito::retOk)
553+
{
554+
checkRetval(locker->returnValue);
555+
}
552556
}
553557
}
554558
}

0 commit comments

Comments
 (0)