Handling wrapping in the mixer code

Hi, in the audio mixer, we do a linear interpolation between two samples, but how does Casey handles the fact that we might read one index past the end of the buffer? In this case, we should rather lerp between buffer[size - 1] and buffer[0], and not buffer[size - 1] and buffer[size]?
It's on the line 231 in handmade_audio.cpp

Edited by Terans on Reason: Initial post
That is handled in asset builder - when it parses wave file and prepares sound asset for runtime, it pads with extra zeroes: https://guide.handmadehero.org/code/day145/#990