diff options
Diffstat (limited to 'alc/backends/null.cpp')
-rw-r--r-- | alc/backends/null.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/alc/backends/null.cpp b/alc/backends/null.cpp index 8692e513..3df75378 100644 --- a/alc/backends/null.cpp +++ b/alc/backends/null.cpp @@ -54,7 +54,7 @@ struct NullBackend final : public BackendBase { void open(const ALCchar *name) override; bool reset() override; - bool start() override; + void start() override; void stop() override; std::atomic<bool> mKillNow{true}; @@ -123,19 +123,16 @@ bool NullBackend::reset() return true; } -bool NullBackend::start() +void NullBackend::start() { try { mKillNow.store(false, std::memory_order_release); mThread = std::thread{std::mem_fn(&NullBackend::mixerProc), this}; - return true; } catch(std::exception& e) { - ERR("Failed to start mixing thread: %s\n", e.what()); + throw al::backend_exception{ALC_INVALID_DEVICE, "Failed to start mixing thread: %s", + e.what()}; } - catch(...) { - } - return false; } void NullBackend::stop() |