renderer: queue hash setting from another thread

Fixes race condition that caused many segfaults.
This commit is contained in:
itsmattkc
2020-08-10 02:09:24 +10:00
parent 4e3cafe578
commit e21b68be53
+5 -1
View File
@@ -524,7 +524,11 @@ void RenderBackend::SetHashes(FrameHashCache* cache, const QVector<rational>& ti
}
}
cache->SetHash(time, hash, job_time, hash_exists);
QMetaObject::invokeMethod(cache, "SetHash", Qt::QueuedConnection,
OLIVE_NS_ARG(rational, time),
Q_ARG(QByteArray, hash),
Q_ARG(qint64, job_time),
Q_ARG(bool, hash_exists));
}
}