Minor fix of sys_lwmutex_destroy
This commit is contained in:
@@ -108,6 +108,12 @@ struct lv2_lwmutex final : lv2_obj
|
||||
}
|
||||
}).signaled;
|
||||
|
||||
if (signal)
|
||||
{
|
||||
cpu->next_cpu = nullptr;
|
||||
}
|
||||
else
|
||||
{
|
||||
const bool notify = lwcond_waiters.fetch_op([](s32& val)
|
||||
{
|
||||
if (val + 0u <= 1u << 31)
|
||||
@@ -127,10 +133,6 @@ struct lv2_lwmutex final : lv2_obj
|
||||
// Notify lwmutex destroyer (may cause EBUSY to be returned for it)
|
||||
lwcond_waiters.notify_all();
|
||||
}
|
||||
|
||||
if (signal)
|
||||
{
|
||||
cpu->next_cpu = nullptr;
|
||||
}
|
||||
|
||||
return signal;
|
||||
|
||||
Reference in New Issue
Block a user