diff options
author | Subv <subv2112@gmail.com> | 2017-01-02 01:23:19 +0100 |
---|---|---|
committer | Subv <subv2112@gmail.com> | 2017-01-05 19:06:17 +0100 |
commit | e52ca85711e8df54c8eafe556b6ba0ca683ddea0 (patch) | |
tree | 5a5842cdea80d830d4295d9a96cb5ff4bfd9162d /src/core/hle/kernel/event.cpp | |
parent | Merge pull request #2390 from jroweboy/bintray (diff) | |
download | yuzu-e52ca85711e8df54c8eafe556b6ba0ca683ddea0.tar yuzu-e52ca85711e8df54c8eafe556b6ba0ca683ddea0.tar.gz yuzu-e52ca85711e8df54c8eafe556b6ba0ca683ddea0.tar.bz2 yuzu-e52ca85711e8df54c8eafe556b6ba0ca683ddea0.tar.lz yuzu-e52ca85711e8df54c8eafe556b6ba0ca683ddea0.tar.xz yuzu-e52ca85711e8df54c8eafe556b6ba0ca683ddea0.tar.zst yuzu-e52ca85711e8df54c8eafe556b6ba0ca683ddea0.zip |
Diffstat (limited to 'src/core/hle/kernel/event.cpp')
-rw-r--r-- | src/core/hle/kernel/event.cpp | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/src/core/hle/kernel/event.cpp b/src/core/hle/kernel/event.cpp index 3e116e3df..a515f53f9 100644 --- a/src/core/hle/kernel/event.cpp +++ b/src/core/hle/kernel/event.cpp @@ -22,11 +22,6 @@ SharedPtr<Event> Event::Create(ResetType reset_type, std::string name) { evt->reset_type = reset_type; evt->name = std::move(name); - if (reset_type == ResetType::Pulse) { - LOG_ERROR(Kernel, "Unimplemented event reset type Pulse"); - UNIMPLEMENTED(); - } - return evt; } @@ -37,8 +32,7 @@ bool Event::ShouldWait() { void Event::Acquire() { ASSERT_MSG(!ShouldWait(), "object unavailable!"); - // Release the event if it's not sticky... - if (reset_type != ResetType::Sticky) + if (reset_type == ResetType::OneShot) signaled = false; } @@ -51,4 +45,11 @@ void Event::Clear() { signaled = false; } +void Event::WakeupAllWaitingThreads() { + WaitObject::WakeupAllWaitingThreads(); + + if (reset_type == ResetType::Pulse) + signaled = false; +} + } // namespace |