diff --git a/playback.cpp b/playback.cpp index 3828cf1..8fe3a00 100644 --- a/playback.cpp +++ b/playback.cpp @@ -9,7 +9,7 @@ size_t CalculateBufSize(SDL_AudioSpec *obtained, double max_seconds, size_t samp return ((((samples_override == 0) ? obtained->samples : samples_override) * max_seconds) + 1) * sizeof(SAMPLETYPE) * obtained->channels; } void Playback::SDLCallbackInner(Uint8 *stream, int len) { - while (st->numSamples() < len) { + while (st->numSamples() <= (uint)len) { general_mixer(NULL, buf, bufsize); st->putSamples((SAMPLETYPE*)buf, bufsize / sizeof(SAMPLETYPE) / spec.channels); }