aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/backends/null.cpp
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2018-12-27 13:40:43 -0800
committerChris Robinson <[email protected]>2018-12-27 13:40:43 -0800
commit4782d6107d250e3528c5e567dca48da727584ee7 (patch)
tree05679c4196c4dacfce65991fa4caa7862cf1c381 /Alc/backends/null.cpp
parent7880f27054cd69cd1e36ebd3d20aa9d6148e3bbd (diff)
Use a proper constructor/destructor for the ALCbackend base
Diffstat (limited to 'Alc/backends/null.cpp')
-rw-r--r--Alc/backends/null.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/Alc/backends/null.cpp b/Alc/backends/null.cpp
index fb113077..2b2a4b84 100644
--- a/Alc/backends/null.cpp
+++ b/Alc/backends/null.cpp
@@ -47,6 +47,8 @@ constexpr ALCchar nullDevice[] = "No Output";
struct ALCnullBackend final : public ALCbackend {
std::atomic<ALenum> mKillNow{AL_TRUE};
std::thread mThread;
+
+ ALCnullBackend(ALCdevice *device) noexcept : ALCbackend{device} { }
};
int ALCnullBackend_mixerProc(ALCnullBackend *self);
@@ -69,14 +71,12 @@ DEFINE_ALCBACKEND_VTABLE(ALCnullBackend);
void ALCnullBackend_Construct(ALCnullBackend *self, ALCdevice *device)
{
- new (self) ALCnullBackend{};
- ALCbackend_Construct(STATIC_CAST(ALCbackend, self), device);
+ new (self) ALCnullBackend{device};
SET_VTABLE2(ALCnullBackend, ALCbackend, self);
}
void ALCnullBackend_Destruct(ALCnullBackend *self)
{
- ALCbackend_Destruct(STATIC_CAST(ALCbackend, self));
self->~ALCnullBackend();
}