diff options
author | Chris Robinson <[email protected]> | 2023-12-29 03:39:58 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2023-12-29 03:39:58 -0800 |
commit | 10ecdff7d1dfcc16bd2a090f089781310ea9a93d (patch) | |
tree | ecd0f09a18f211ca7df2120e7c998aa037f5dfe4 /alc/context.cpp | |
parent | 768781bab97732fbd0d66fa153d4ebc768be1240 (diff) |
Handle pointer ownership a bit better
Diffstat (limited to 'alc/context.cpp')
-rw-r--r-- | alc/context.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/alc/context.cpp b/alc/context.cpp index b5db03f9..0f6dbbae 100644 --- a/alc/context.cpp +++ b/alc/context.cpp @@ -338,10 +338,10 @@ void ForEachSource(ALCcontext *context, F func) uint64_t usemask{~sublist.FreeMask}; while(usemask) { - const int idx{al::countr_zero(usemask)}; + const auto idx = static_cast<uint>(al::countr_zero(usemask)); usemask &= ~(1_u64 << idx); - func(sublist.Sources[idx]); + func((*sublist.Sources)[idx]); } } } |