From 21aaa18c500c554fc6af39d9256b83cff8d07516 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Mon, 11 Feb 2019 11:14:34 -0800 Subject: Get rid of the FAM_SIZE macro --- OpenAL32/Include/alSource.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'OpenAL32/Include/alSource.h') diff --git a/OpenAL32/Include/alSource.h b/OpenAL32/Include/alSource.h index d02dbd5b..0343a943 100644 --- a/OpenAL32/Include/alSource.h +++ b/OpenAL32/Include/alSource.h @@ -21,6 +21,12 @@ struct ALbufferlistitem { ALsizei max_samples; ALsizei num_buffers; ALbuffer *buffers[]; + + static constexpr size_t Sizeof(size_t num_buffers) noexcept + { + return maxz(offsetof(ALbufferlistitem, buffers) + sizeof(ALbuffer*)*num_buffers, + sizeof(ALbufferlistitem)); + } }; -- cgit v1.2.3