mirror of
https://gitee.com/openharmony/third_party_libsnd
synced 2025-02-17 09:29:53 +00:00
src/wavlike.c: Prevent infinite loop on malformed file
Found using American Fuzzy Lop.
This commit is contained in:
parent
7b7e0d913b
commit
afcf447499
@ -939,7 +939,8 @@ wavlike_subchunk_parse (SF_PRIVATE *psf, int chunk, uint32_t chunk_length)
|
||||
|
||||
case exif_MARKER :
|
||||
psf_log_printf (psf, " %M\n", chunk) ;
|
||||
bytesread += exif_subchunk_parse (psf, chunk_length - bytesread) ;
|
||||
if (chunk_length > bytesread)
|
||||
bytesread += exif_subchunk_parse (psf, chunk_length - bytesread) ;
|
||||
continue ;
|
||||
|
||||
case data_MARKER :
|
||||
|
Loading…
x
Reference in New Issue
Block a user