Remove some redundant error checks.

This commit is contained in:
David Reid
2026-01-07 12:05:57 +10:00
parent 8c4535c6c5
commit d791c16d8d
+6 -12
View File
@@ -66278,11 +66278,9 @@ static ma_result ma_decoder_init__internal(ma_decoder_read_proc onRead, ma_decod
We use trial and error to open a decoder. We prioritize custom decoders so that if they
implement the same encoding format they take priority over the built-in decoders.
*/
result = ma_decoder_init_custom__internal(pConfig, pDecoder);
if (result != MA_SUCCESS) {
result = ma_decoder_init_custom__internal(pConfig, pDecoder);
if (result != MA_SUCCESS) {
onSeek(pDecoder, 0, ma_seek_origin_start);
}
onSeek(pDecoder, 0, ma_seek_origin_start);
}
/*
@@ -66846,11 +66844,9 @@ MA_API ma_result ma_decoder_init_vfs(ma_vfs* pVFS, const char* pFilePath, const
We use trial and error to open a decoder. We prioritize custom decoders so that if they
implement the same encoding format they take priority over the built-in decoders.
*/
result = ma_decoder_init_custom__internal(&config, pDecoder);
if (result != MA_SUCCESS) {
result = ma_decoder_init_custom__internal(&config, pDecoder);
if (result != MA_SUCCESS) {
ma_decoder__on_seek_vfs(pDecoder, 0, ma_seek_origin_start);
}
ma_decoder__on_seek_vfs(pDecoder, 0, ma_seek_origin_start);
}
/*
@@ -66979,11 +66975,9 @@ MA_API ma_result ma_decoder_init_vfs_w(ma_vfs* pVFS, const wchar_t* pFilePath, c
We use trial and error to open a decoder. We prioritize custom decoders so that if they
implement the same encoding format they take priority over the built-in decoders.
*/
result = ma_decoder_init_custom__internal(&config, pDecoder);
if (result != MA_SUCCESS) {
result = ma_decoder_init_custom__internal(&config, pDecoder);
if (result != MA_SUCCESS) {
ma_decoder__on_seek_vfs(pDecoder, 0, ma_seek_origin_start);
}
ma_decoder__on_seek_vfs(pDecoder, 0, ma_seek_origin_start);
}
/*