aboutsummaryrefslogtreecommitdiffstats
path: root/OpenAL32/alAuxEffectSlot.c
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2016-07-06 13:33:40 -0700
committerChris Robinson <[email protected]>2016-07-06 13:33:40 -0700
commitb495d80f5624328569bd0d8b9478927c0fc32100 (patch)
tree8e8d167cf5fa90b9adf22f5bf855430be819f17d /OpenAL32/alAuxEffectSlot.c
parentd096e183a8d1e20ed2a71d502897394a14bf8404 (diff)
Avoid using memcpy to copy a single struct
Diffstat (limited to 'OpenAL32/alAuxEffectSlot.c')
-rw-r--r--OpenAL32/alAuxEffectSlot.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/OpenAL32/alAuxEffectSlot.c b/OpenAL32/alAuxEffectSlot.c
index bbaf0668..14066cf9 100644
--- a/OpenAL32/alAuxEffectSlot.c
+++ b/OpenAL32/alAuxEffectSlot.c
@@ -511,7 +511,7 @@ ALenum InitializeEffect(ALCdevice *Device, ALeffectslot *EffectSlot, ALeffect *e
else
{
EffectSlot->Effect.Type = effect->type;
- memcpy(&EffectSlot->Effect.Props, &effect->Props, sizeof(EffectSlot->Effect.Props));
+ EffectSlot->Effect.Props = effect->Props;
}
EffectSlot->Effect.State = State;
@@ -519,7 +519,7 @@ ALenum InitializeEffect(ALCdevice *Device, ALeffectslot *EffectSlot, ALeffect *e
}
else if(effect)
{
- memcpy(&EffectSlot->Effect.Props, &effect->Props, sizeof(EffectSlot->Effect.Props));
+ EffectSlot->Effect.Props = effect->Props;
UpdateEffectSlotProps(EffectSlot);
}
@@ -630,7 +630,7 @@ void UpdateEffectSlotProps(ALeffectslot *slot)
ATOMIC_STORE(&props->AuxSendAuto, slot->AuxSendAuto, almemory_order_relaxed);
ATOMIC_STORE(&props->Type, slot->Effect.Type, almemory_order_relaxed);
- memcpy(&props->Props, &slot->Effect.Props, sizeof(props->Props));
+ props->Props = slot->Effect.Props;
/* Swap out any stale effect state object there may be in the container, to
* delete it.
*/