Commit 339e748c authored by Anna Medonosová's avatar Anna Medonosová

Use regular asserts in KisDocument::slotChildCompletedSavingInBackground

Use KIS_ASSERT instead of KIS_SAFE_ASSERT in
KisDocument::slotChildCompletedSavingInBackground. When any of these
conditions triggers, it means that something is really wrong and the
saved file may be corrupt. On systems with safe asserts hidden (e.g.
Windows), there is no feedback to the user that something bad happened
(apart from the fact that the document is still modified after save).
parent d8be8f20
......@@ -996,9 +996,9 @@ bool KisDocument::initiateSavingInBackground(const QString actionName,
void KisDocument::slotChildCompletedSavingInBackground(KisImportExportErrorCode status, const QString &errorMessage)
{
KIS_SAFE_ASSERT_RECOVER_RETURN(isSaving());
KIS_ASSERT_RECOVER_RETURN(isSaving());
KIS_SAFE_ASSERT_RECOVER(d->backgroundSaveDocument) {
KIS_ASSERT_RECOVER(d->backgroundSaveDocument) {
d->savingMutex.unlock();
return;
}
......@@ -1009,7 +1009,7 @@ void KisDocument::slotChildCompletedSavingInBackground(KisImportExportErrorCode
d->backgroundSaveDocument.take()->deleteLater();
KIS_SAFE_ASSERT_RECOVER(d->backgroundSaveJob.isValid()) {
KIS_ASSERT_RECOVER(d->backgroundSaveJob.isValid()) {
d->savingMutex.unlock();
return;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment