From b49ce86765f5ced6935a33ce5a08604ea973b3c6 Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Sat, 29 Jul 2023 19:43:41 -0400 Subject: [PATCH] audio: Fixed compiler warning on Android NDK. --- src/audio/SDL_audiocvt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/audio/SDL_audiocvt.c b/src/audio/SDL_audiocvt.c index d7e2c54f4..0098504e2 100644 --- a/src/audio/SDL_audiocvt.c +++ b/src/audio/SDL_audiocvt.c @@ -1036,7 +1036,7 @@ int SDL_GetAudioStreamData(SDL_AudioStream *stream, void *voidbuf, int len) int approx_request = len / stream->dst_sample_frame_size; // start with sample frames desired if (stream->src_spec.freq != stream->dst_spec.freq) { // calculate difference in dataset size after resampling. Use a Uint64 so the multiplication doesn't overflow. - approx_request = (size_t) ((((Uint64) approx_request) * stream->src_spec.freq) / stream->dst_spec.freq); + approx_request = (int) (size_t) ((((Uint64) approx_request) * stream->src_spec.freq) / stream->dst_spec.freq); if (!stream->flushed) { // do we need to fill the future buffer to accomodate this, too? approx_request += stream->future_buffer_filled_frames - stream->resampler_padding_frames; }