mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-20 22:05:12 +00:00
idm: Fix minor race in cellVdecClose, sys_raw_spu_destroy...
Because of racing removal of IDs vs the shared pointer owned object
This commit is contained in:
parent
efe6e1eb0a
commit
c16124f0d9
6 changed files with 33 additions and 20 deletions
|
|
@ -117,15 +117,11 @@ error_code sceNpSnsFbDestroyHandle(u32 handle)
|
|||
return SCE_NP_SNS_ERROR_INVALID_ARGUMENT;
|
||||
}
|
||||
|
||||
const auto sfh = idm::get<sns_fb_handle_t>(handle);
|
||||
|
||||
if (!sfh)
|
||||
if (!idm::remove<sns_fb_handle_t>(handle))
|
||||
{
|
||||
return SCE_NP_SNS_FB_ERROR_UNKNOWN_HANDLE;
|
||||
}
|
||||
|
||||
idm::remove<sns_fb_handle_t>(handle);
|
||||
|
||||
return CELL_OK;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue