mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2026-11-06 05:17:42 +00:00
avformat/mov: fix leak of the gain map parameters when the tmap payload allocation fails
The payload size is the item's extent length from the file, so the allocation can fail for a crafted file. Leak Replicated through UnModified FFmpeg with LSAN Found by a grok bot based audit of the code.
This commit is contained in:
1 parent
00edc310fa
commit
4b1149c8eb
1 file changed
+1
-1
+1
-1
@@ -11662,7 +11662,7 @@ static int mov_parse_heif_layered_video_tmap(AVFormatContext *s, const HEIFGroup
|
||||
|
||||
payload = av_malloc(tmap->item->extent_length);
|
||||
if (!payload) {
|
||||
return AVERROR(ENOMEM);
|
||||
err = AVERROR(ENOMEM);
|
||||
goto fail;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user