From bef32b4419502055f35bbd4959f7de23362a91f4 Mon Sep 17 00:00:00 2001 From: David Reid Date: Thu, 22 Jan 2026 11:34:35 +1000 Subject: [PATCH] Fix a null pointer dereference in the audio queue. --- miniaudio.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/miniaudio.h b/miniaudio.h index 051085db..f7268a45 100644 --- a/miniaudio.h +++ b/miniaudio.h @@ -66416,7 +66416,9 @@ MA_API ma_result ma_audio_queue_read_pcm_frames(ma_audio_queue* pAudioQueue, voi } ma_spinlock_unlock(&pAudioQueue->lock); - *pFramesRead = frameCount; + if (pFramesRead != NULL) { + *pFramesRead = frameCount; + } /* Note that we never returning MA_AT_END for a queue because there isn't really a notion of it. */ return MA_SUCCESS;