You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In check_sanity() function,
In the scenario where multiple processes share the same shared memory, if the shared memory is corrupted for some reason then when one of the processes calls check_sanity() the scoped mutex in the function locks but the process crashes with assertion without unlocking the mutex, causing any other process that will call check_sanity() to be stuck on the locked scoped mutex.
If there is a mutex in a shared memory object it must be unlocked before assertion, exception, or return.
I would expect the check_sanity() function to return false in the case of corrupted memory instead of assert.
The text was updated successfully, but these errors were encountered:
lioriz
changed the title
check_sanity() scoped mutex lock after assertion
check_sanity() scoped mutex locked after assertion
Jun 13, 2022
In check_sanity() function,
In the scenario where multiple processes share the same
shared memory
, if theshared memory
is corrupted for some reason then when one of the processes callscheck_sanity()
the scoped mutex in the function locks but the process crashes with assertion without unlocking the mutex, causing any other process that will callcheck_sanity()
to be stuck on the lockedscoped mutex
.If there is a
mutex
in ashared memory
object it must be unlocked beforeassertion
,exception
, orreturn
.I would expect the
check_sanity()
function to returnfalse
in the case of corrupted memory instead ofassert
.The text was updated successfully, but these errors were encountered: