diff options
Diffstat (limited to 'OpenAL32/event.cpp')
-rw-r--r-- | OpenAL32/event.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/OpenAL32/event.cpp b/OpenAL32/event.cpp index 1a4e1df0..ad3fd4ab 100644 --- a/OpenAL32/event.cpp +++ b/OpenAL32/event.cpp @@ -18,9 +18,9 @@ static int EventThread(ALCcontext *context) { bool quitnow{false}; + AsyncEvent evt{}; while(LIKELY(!quitnow)) { - AsyncEvent evt; if(ll_ringbuffer_read(context->AsyncEvents, &evt, 1) == 0) { context->EventSem.wait(); @@ -90,7 +90,7 @@ void StartEventThrd(ALCcontext *ctx) void StopEventThrd(ALCcontext *ctx) { - static constexpr AsyncEvent kill_evt = ASYNC_EVENT(EventType_KillThread); + static constexpr AsyncEvent kill_evt{EventType_KillThread}; while(ll_ringbuffer_write(ctx->AsyncEvents, &kill_evt, 1) == 0) std::this_thread::yield(); ctx->EventSem.post(); |