From f48be9d73b4472570d28bf381d84e40cf65694c8 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Sun, 18 Nov 2018 03:59:39 -0800 Subject: Remove the pointer-specific atomic exchange macros --- OpenAL32/alSource.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'OpenAL32/alSource.cpp') diff --git a/OpenAL32/alSource.cpp b/OpenAL32/alSource.cpp index 7f54767a..8b08728a 100644 --- a/OpenAL32/alSource.cpp +++ b/OpenAL32/alSource.cpp @@ -3168,7 +3168,7 @@ static void UpdateSourceProps(ALsource *source, ALvoice *voice, ALsizei num_send struct ALvoiceProps *next; do { next = ATOMIC_LOAD(&props->next, almemory_order_relaxed); - } while(ATOMIC_COMPARE_EXCHANGE_PTR_WEAK(&context->FreeVoiceProps, &props, next, + } while(ATOMIC_COMPARE_EXCHANGE_WEAK(&context->FreeVoiceProps, &props, next, almemory_order_acq_rel, almemory_order_acquire) == 0); } @@ -3232,8 +3232,7 @@ static void UpdateSourceProps(ALsource *source, ALvoice *voice, ALsizei num_send } /* Set the new container for updating internal parameters. */ - props = static_cast(ATOMIC_EXCHANGE_PTR(&voice->Update, props, - almemory_order_acq_rel)); + props = ATOMIC_EXCHANGE(&voice->Update, props, almemory_order_acq_rel); if(props) { /* If there was an unused update container, put it back in the -- cgit v1.2.3