From ffbf0db4b64c5a506105a685daaef261567ae972 Mon Sep 17 00:00:00 2001 From: Tsiry Sandratraina Date: Mon, 23 Dec 2024 15:27:11 +0000 Subject: [PATCH] pcm: fix incorrect process_buffer params --- apps/pcm_thread.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/apps/pcm_thread.c b/apps/pcm_thread.c index fcdde4163e..5081e322a3 100644 --- a/apps/pcm_thread.c +++ b/apps/pcm_thread.c @@ -118,8 +118,6 @@ static void process_audio(SDL_AudioCVT *cvt, Uint8 *data, size_t *data_size) { converted_size = chunk_size; } - debugfn("Data size: %d", *data_size); - // Accumulate data into the final output memcpy(data + *data_size, conv_buffer, converted_size); *data_size += converted_size; @@ -127,7 +125,8 @@ static void process_audio(SDL_AudioCVT *cvt, Uint8 *data, size_t *data_size) { // Update pointers/counters curr_data += chunk_size; remaining -= chunk_size; - process_pcm_buffer(conv_buffer, converted_size); + process_pcm_buffer(data, *data_size); + debugfn("Data size: %d", *data_size); } free(stream);