diff options
author | Chris Robinson <[email protected]> | 2018-12-27 13:40:43 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2018-12-27 13:40:43 -0800 |
commit | 4782d6107d250e3528c5e567dca48da727584ee7 (patch) | |
tree | 05679c4196c4dacfce65991fa4caa7862cf1c381 /Alc/backends/jack.cpp | |
parent | 7880f27054cd69cd1e36ebd3d20aa9d6148e3bbd (diff) |
Use a proper constructor/destructor for the ALCbackend base
Diffstat (limited to 'Alc/backends/jack.cpp')
-rw-r--r-- | Alc/backends/jack.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Alc/backends/jack.cpp b/Alc/backends/jack.cpp index ca537323..059f9c96 100644 --- a/Alc/backends/jack.cpp +++ b/Alc/backends/jack.cpp @@ -157,6 +157,8 @@ struct ALCjackPlayback final : public ALCbackend { std::atomic<bool> mKillNow{true}; std::thread mThread; + + ALCjackPlayback(ALCdevice *device) noexcept : ALCbackend{device} { } }; int ALCjackPlayback_bufferSizeNotify(jack_nframes_t numframes, void *arg); @@ -182,8 +184,7 @@ DEFINE_ALCBACKEND_VTABLE(ALCjackPlayback); void ALCjackPlayback_Construct(ALCjackPlayback *self, ALCdevice *device) { - new (self) ALCjackPlayback{}; - ALCbackend_Construct(STATIC_CAST(ALCbackend, self), device); + new (self) ALCjackPlayback{device}; SET_VTABLE2(ALCjackPlayback, ALCbackend, self); } @@ -200,7 +201,6 @@ void ALCjackPlayback_Destruct(ALCjackPlayback *self) self->mClient = nullptr; } - ALCbackend_Destruct(STATIC_CAST(ALCbackend, self)); self->~ALCjackPlayback(); } |