summaryrefslogtreecommitdiffstats
path: root/src/core/hle/kernel/readable_event.cpp
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2020-02-14 20:40:20 +0100
committerGitHub <noreply@github.com>2020-02-14 20:40:20 +0100
commitf552d553bac1374c583d748dad27f8c86e86c4a0 (patch)
tree1da4aa037ff417fa4fd43bffac267dcb2b55a72d /src/core/hle/kernel/readable_event.cpp
parentMerge pull request #3379 from ReinUsesLisp/cbuf-offset (diff)
parentCore: Correct compilition in GCC (diff)
downloadyuzu-f552d553bac1374c583d748dad27f8c86e86c4a0.tar
yuzu-f552d553bac1374c583d748dad27f8c86e86c4a0.tar.gz
yuzu-f552d553bac1374c583d748dad27f8c86e86c4a0.tar.bz2
yuzu-f552d553bac1374c583d748dad27f8c86e86c4a0.tar.lz
yuzu-f552d553bac1374c583d748dad27f8c86e86c4a0.tar.xz
yuzu-f552d553bac1374c583d748dad27f8c86e86c4a0.tar.zst
yuzu-f552d553bac1374c583d748dad27f8c86e86c4a0.zip
Diffstat (limited to 'src/core/hle/kernel/readable_event.cpp')
-rw-r--r--src/core/hle/kernel/readable_event.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/core/hle/kernel/readable_event.cpp b/src/core/hle/kernel/readable_event.cpp
index d8ac97aa1..9d3d3a81b 100644
--- a/src/core/hle/kernel/readable_event.cpp
+++ b/src/core/hle/kernel/readable_event.cpp
@@ -11,30 +11,30 @@
namespace Kernel {
-ReadableEvent::ReadableEvent(KernelCore& kernel) : WaitObject{kernel} {}
+ReadableEvent::ReadableEvent(KernelCore& kernel) : SynchronizationObject{kernel} {}
ReadableEvent::~ReadableEvent() = default;
bool ReadableEvent::ShouldWait(const Thread* thread) const {
- return !signaled;
+ return !is_signaled;
}
void ReadableEvent::Acquire(Thread* thread) {
- ASSERT_MSG(!ShouldWait(thread), "object unavailable!");
+ ASSERT_MSG(IsSignaled(), "object unavailable!");
}
void ReadableEvent::Signal() {
- if (!signaled) {
- signaled = true;
- WakeupAllWaitingThreads();
+ if (!is_signaled) {
+ is_signaled = true;
+ SynchronizationObject::Signal();
};
}
void ReadableEvent::Clear() {
- signaled = false;
+ is_signaled = false;
}
ResultCode ReadableEvent::Reset() {
- if (!signaled) {
+ if (!is_signaled) {
return ERR_INVALID_STATE;
}