event/Thread: add "noexcept"

This commit is contained in:
Max Kellermann 2018-01-29 23:11:15 +01:00
parent 3fd9a86f3c
commit 19af364400
2 changed files with 6 additions and 6 deletions

View File

@ -30,7 +30,7 @@ EventThread::Start()
}
void
EventThread::Stop()
EventThread::Stop() noexcept
{
if (thread.IsDefined()) {
event_loop.Break();
@ -39,7 +39,7 @@ EventThread::Stop()
}
void
EventThread::Run()
EventThread::Run() noexcept
{
SetThreadName("io");

View File

@ -36,20 +36,20 @@ public:
EventThread()
:event_loop(ThreadId::Null()), thread(BIND_THIS_METHOD(Run)) {}
~EventThread() {
~EventThread() noexcept {
Stop();
}
EventLoop &GetEventLoop() {
EventLoop &GetEventLoop() noexcept {
return event_loop;
}
void Start();
void Stop();
void Stop() noexcept;
private:
void Run();
void Run() noexcept;
};
#endif /* MAIN_NOTIFY_H */