1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-01-24 13:56:33 +02:00

riff: fix invalid av_freep() calls on EOF in ff_read_riff_info

This commit is contained in:
Janne Grunau 2012-01-05 20:15:53 +01:00
parent 66b9d7065a
commit 15cea3695d

View File

@ -669,8 +669,7 @@ int ff_read_riff_info(AVFormatContext *s, int64_t size)
AV_WL32(key, chunk_code);
if (avio_read(pb, value, chunk_size) != chunk_size) {
av_freep(key);
av_freep(value);
av_free(value);
av_log(s, AV_LOG_ERROR, "premature end of file while reading INFO tag\n");
return AVERROR_INVALIDDATA;
}