diff options
author | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2019-12-10 11:47:57 +0100 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2021-02-27 07:20:58 +0100 |
commit | 8372a3b4b1d1bd77a008d92d83a8fbd53e736231 (patch) | |
tree | e677f5ce400ab777e819cec5407d99850f247a79 /libavformat/oma.h | |
parent | b7ad5dbb5e29085cdd7c38daeaf2507ee09f6b76 (diff) | |
download | ffmpeg-8372a3b4b1d1bd77a008d92d83a8fbd53e736231.tar.gz |
avformat/apngdec: Return error for incomplete header
If avio_read() could read anything, it returns the number of bytes read,
even if it could not read as much as the caller desired.
apng_read_header() only checked the return value of its avio_read() calls
for being negative and this meant that it was possible for an incomplete
header to not be detected. The return value of the last successfull call
has been returned instead. This commit changes this.
Fixes: OOM
Fixes: 26608/clusterfuzz-testcase-minimized-ffmpeg_dem_APNG_fuzzer-4839491644424192
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
(cherry picked from commit 2cf1eefae5dba7a7259156f9ff5c62f4e4e2fe0d)
Diffstat (limited to 'libavformat/oma.h')
0 files changed, 0 insertions, 0 deletions