summaryrefslogtreecommitdiffstats
path: root/src/core/hle/kernel/timer.cpp
diff options
context:
space:
mode:
authorYuri Kunde Schlesner <yuriks@yuriks.net>2015-02-01 03:14:40 +0100
committerYuri Kunde Schlesner <yuriks@yuriks.net>2015-02-02 18:37:09 +0100
commit88a4a808c688eeabb136e9b45223a0e9c95896bc (patch)
treec4181a69ff882e1af1b7d65bf3596a6cb3dd88b9 /src/core/hle/kernel/timer.cpp
parentKernel: Make WaitObjects share ownership of Threads waiting on them (diff)
downloadyuzu-88a4a808c688eeabb136e9b45223a0e9c95896bc.tar
yuzu-88a4a808c688eeabb136e9b45223a0e9c95896bc.tar.gz
yuzu-88a4a808c688eeabb136e9b45223a0e9c95896bc.tar.bz2
yuzu-88a4a808c688eeabb136e9b45223a0e9c95896bc.tar.lz
yuzu-88a4a808c688eeabb136e9b45223a0e9c95896bc.tar.xz
yuzu-88a4a808c688eeabb136e9b45223a0e9c95896bc.tar.zst
yuzu-88a4a808c688eeabb136e9b45223a0e9c95896bc.zip
Diffstat (limited to 'src/core/hle/kernel/timer.cpp')
-rw-r--r--src/core/hle/kernel/timer.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/core/hle/kernel/timer.cpp b/src/core/hle/kernel/timer.cpp
index 7c3cdc0d0..4352fc99c 100644
--- a/src/core/hle/kernel/timer.cpp
+++ b/src/core/hle/kernel/timer.cpp
@@ -20,10 +20,8 @@ static Kernel::HandleTable timer_callback_handle_table;
Timer::Timer() {}
Timer::~Timer() {}
-ResultVal<SharedPtr<Timer>> Timer::Create(ResetType reset_type, std::string name) {
+SharedPtr<Timer> Timer::Create(ResetType reset_type, std::string name) {
SharedPtr<Timer> timer(new Timer);
- // TOOD(yuriks): Don't create Handle (see Thread::Create())
- CASCADE_RESULT(auto unused, Kernel::g_handle_table.Create(timer));
timer->reset_type = reset_type;
timer->signaled = false;
@@ -31,7 +29,8 @@ ResultVal<SharedPtr<Timer>> Timer::Create(ResetType reset_type, std::string name
timer->initial_delay = 0;
timer->interval_delay = 0;
timer->callback_handle = timer_callback_handle_table.Create(timer).MoveFrom();
- return MakeResult<SharedPtr<Timer>>(timer);
+
+ return timer;
}
bool Timer::ShouldWait() {