From 0595e5099ed153b6ca6e8836a5528ed7e8d7b5ef Mon Sep 17 00:00:00 2001 From: "Unknown W. Brackets" Date: Sat, 6 Apr 2013 12:29:30 -0700 Subject: [PATCH] Don't allow wait in event flags without dispatch. But this happens after other param checks. --- Core/HLE/sceKernelEventFlag.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Core/HLE/sceKernelEventFlag.cpp b/Core/HLE/sceKernelEventFlag.cpp index 4d28a4c057..1e8a41ed97 100644 --- a/Core/HLE/sceKernelEventFlag.cpp +++ b/Core/HLE/sceKernelEventFlag.cpp @@ -390,6 +390,9 @@ int sceKernelWaitEventFlag(SceUID id, u32 bits, u32 wait, u32 outBitsPtr, u32 ti if (bits == 0) return SCE_KERNEL_ERROR_EVF_ILPAT; + if (!__KernelIsDispatchEnabled()) + return SCE_KERNEL_ERROR_CAN_NOT_WAIT; + u32 error; EventFlag *e = kernelObjects.Get(id, error); if (e) @@ -443,6 +446,9 @@ int sceKernelWaitEventFlagCB(SceUID id, u32 bits, u32 wait, u32 outBitsPtr, u32 if (bits == 0) return SCE_KERNEL_ERROR_EVF_ILPAT; + if (!__KernelIsDispatchEnabled()) + return SCE_KERNEL_ERROR_CAN_NOT_WAIT; + u32 error; EventFlag *e = kernelObjects.Get(id, error); if (e)