summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/core/hle/kernel/k_address_arbiter.cpp13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/core/hle/kernel/k_address_arbiter.cpp b/src/core/hle/kernel/k_address_arbiter.cpp
index 3c3e51dbe..d0e90fd60 100644
--- a/src/core/hle/kernel/k_address_arbiter.cpp
+++ b/src/core/hle/kernel/k_address_arbiter.cpp
@@ -118,9 +118,10 @@ ResultCode KAddressArbiter::SignalAndIncrementIfEqual(VAddr addr, s32 value, s32
// Check the userspace value.
s32 user_value{};
- R_UNLESS(UpdateIfEqual(system, &user_value, addr, value, value + 1),
- Svc::ResultInvalidCurrentMemory);
-
+ if (!UpdateIfEqual(system, &user_value, addr, value, value + 1)) {
+ LOG_ERROR(Kernel, "Invalid current memory!");
+ return Svc::ResultInvalidCurrentMemory;
+ }
if (user_value != value) {
return Svc::ResultInvalidState;
}
@@ -186,8 +187,10 @@ ResultCode KAddressArbiter::SignalAndModifyByWaitingCountIfEqual(VAddr addr, s32
succeeded = ReadFromUser(system, &user_value, addr);
}
- R_UNLESS(succeeded, Svc::ResultInvalidCurrentMemory);
-
+ if (!succeeded) {
+ LOG_ERROR(Kernel, "Invalid current memory!");
+ return Svc::ResultInvalidCurrentMemory;
+ }
if (user_value != value) {
return Svc::ResultInvalidState;
}