From d1abdd100ba05b612d22059ec04d40763ce9a5f2 Mon Sep 17 00:00:00 2001 From: David Hill Date: Wed, 16 Oct 2024 17:52:41 +0000 Subject: [PATCH] fix crash in ma_device_uninit when using sndio --- miniaudio.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/miniaudio.h b/miniaudio.h index 66b219a4..26083cca 100644 --- a/miniaudio.h +++ b/miniaudio.h @@ -35635,7 +35635,7 @@ static ma_result ma_device_uninit__sndio(ma_device* pDevice) ((ma_sio_close_proc)pDevice->pContext->sndio.sio_close)((struct ma_sio_hdl*)pDevice->sndio.handleCapture); } - if (pDevice->type == ma_device_type_capture || pDevice->type == ma_device_type_duplex) { + if (pDevice->type == ma_device_type_playback || pDevice->type == ma_device_type_duplex) { ((ma_sio_close_proc)pDevice->pContext->sndio.sio_close)((struct ma_sio_hdl*)pDevice->sndio.handlePlayback); }