diff options
author | Chris Robinson <[email protected]> | 2023-03-05 00:29:24 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2023-03-05 00:29:24 -0800 |
commit | 442cfdd14ea01f8c9d494d544213b40dc696841f (patch) | |
tree | 596394350052bfc31b6eef99965ad138a55823a2 /examples/alplay.c | |
parent | ef45eccd6cbf736aa4a364b92e6089568091ed2e (diff) |
Make sure the fmt chunk is large enough
Diffstat (limited to 'examples/alplay.c')
-rw-r--r-- | examples/alplay.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/alplay.c b/examples/alplay.c index e477df28..6f6c8699 100644 --- a/examples/alplay.c +++ b/examples/alplay.c @@ -122,7 +122,7 @@ static ALuint LoadSound(const char *filename) /* If there's an issue getting the chunk or block alignment, load as * 16-bit and have libsndfile do the conversion. */ - if(!iter || sf_get_chunk_size(iter, &inf) != SF_ERR_NO_ERROR) + if(!iter || sf_get_chunk_size(iter, &inf) != SF_ERR_NO_ERROR || inf.datalen < 14) sample_format = Int16; else { |