From 0c99a6b316b7e52c12a25d50550291562430834d Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Fri, 19 Nov 2021 20:04:10 -0800 Subject: Make the backend pointer part of ALCdevice instead of DeviceBase --- alc/device.cpp | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) (limited to 'alc/device.cpp') diff --git a/alc/device.cpp b/alc/device.cpp index 41ef6d44..01153d51 100644 --- a/alc/device.cpp +++ b/alc/device.cpp @@ -25,17 +25,8 @@ using voidp = void*; } // namespace -/* This should be in core/device.cpp. */ -DeviceBase::DeviceBase(DeviceType type) : Type{type}, mContexts{&sEmptyContextArray} -{ -} - -DeviceBase::~DeviceBase() -{ - auto *oldarray = mContexts.exchange(nullptr, std::memory_order_relaxed); - if(oldarray != &sEmptyContextArray) delete oldarray; -} - +ALCdevice::ALCdevice(DeviceType type) : DeviceBase{type} +{ } ALCdevice::~ALCdevice() { -- cgit v1.2.3