lv2: Check ipc_key value if object is process shared

This commit is contained in:
Eladash 2019-11-01 21:22:43 +02:00 committed by Ivan
parent d2f3ada312
commit 7475be99ab
2 changed files with 10 additions and 0 deletions

View file

@ -420,6 +420,11 @@ error_code sys_event_port_connect_ipc(ppu_thread& ppu, u32 eport_id, u64 ipc_key
sys_event.warning("sys_event_port_connect_ipc(eport_id=0x%x, ipc_key=0x%x)", eport_id, ipc_key);
if (ipc_key == 0)
{
return CELL_EINVAL;
}
auto queue = lv2_event_queue::find(ipc_key);
std::lock_guard lock(id_manager::g_mutex);

View file

@ -162,6 +162,11 @@ public:
{
case SYS_SYNC_PROCESS_SHARED:
{
if (ipc_key == 0)
{
return CELL_EINVAL;
}
switch (flags)
{
case SYS_SYNC_NEWLY_CREATED: