fix for leaks of coroutine handle

This commit is contained in:
psucien 2024-05-26 18:18:32 +02:00 committed by georgemoralis
parent 2963790e0d
commit 09c7379fe0

View file

@ -54,6 +54,8 @@ void Liverpool::Process(std::stop_token stoken) {
task.resume(); task.resume();
if (task.done()) { if (task.done()) {
task.destroy();
std::scoped_lock lock{queue.m_access}; std::scoped_lock lock{queue.m_access};
queue.submits.pop(); queue.submits.pop();
@ -268,6 +270,7 @@ Liverpool::Task Liverpool::ProcessGraphics(std::span<const u32> dcb, std::span<c
if (ce_task.handle) { if (ce_task.handle) {
ASSERT_MSG(ce_task.handle.done(), "Partially processed CCB"); ASSERT_MSG(ce_task.handle.done(), "Partially processed CCB");
ce_task.handle.destroy();
} }
} }