Properly propagate errors from ma_decoder_read_pcm_frames().

This commit is contained in:
David Reid
2021-07-10 19:15:19 +10:00
parent 6dec8c0736
commit bd53d105d3
+2 -2
View File
@@ -50226,8 +50226,8 @@ MA_API ma_result ma_decoder_read_pcm_frames(ma_decoder* pDecoder, void* pFramesO
*pFramesRead = totalFramesReadOut;
}
if (totalFramesReadOut == 0) {
return MA_AT_END;
if (result == MA_SUCCESS && totalFramesReadOut == 0) {
result = MA_AT_END;
}
return result;