lv2: Check ipc_key value if object is process shared
This commit is contained in:
@@ -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);
|
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);
|
auto queue = lv2_event_queue::find(ipc_key);
|
||||||
|
|
||||||
std::lock_guard lock(id_manager::g_mutex);
|
std::lock_guard lock(id_manager::g_mutex);
|
||||||
|
|||||||
@@ -162,6 +162,11 @@ public:
|
|||||||
{
|
{
|
||||||
case SYS_SYNC_PROCESS_SHARED:
|
case SYS_SYNC_PROCESS_SHARED:
|
||||||
{
|
{
|
||||||
|
if (ipc_key == 0)
|
||||||
|
{
|
||||||
|
return CELL_EINVAL;
|
||||||
|
}
|
||||||
|
|
||||||
switch (flags)
|
switch (flags)
|
||||||
{
|
{
|
||||||
case SYS_SYNC_NEWLY_CREATED:
|
case SYS_SYNC_NEWLY_CREATED:
|
||||||
|
|||||||
Reference in New Issue
Block a user