ffmpeg | branch: master | Tristan Matthews <tma...@videolan.org> | Thu Apr 4 12:56:26 2019 -0400| [1ec777dcdd03b43d3d694c3b4532dccea0b419f0] | committer: James Almer
avformat/matroskaenc: fix leak on error Signed-off-by: James Almer <jamr...@gmail.com> > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=1ec777dcdd03b43d3d694c3b4532dccea0b419f0 --- libavformat/matroskaenc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libavformat/matroskaenc.c b/libavformat/matroskaenc.c index 06f3aeb46d..1c98c0dceb 100644 --- a/libavformat/matroskaenc.c +++ b/libavformat/matroskaenc.c @@ -694,8 +694,10 @@ static int put_flac_codecpriv(AVFormatContext *s, av_dict_set(&dict, "WAVEFORMATEXTENSIBLE_CHANNEL_MASK", buf, 0); len = ff_vorbiscomment_length(dict, vendor, NULL, 0); - if (len >= ((1<<24) - 4)) + if (len >= ((1<<24) - 4)) { + av_dict_free(&dict); return AVERROR(EINVAL); + } data = av_malloc(len + 4); if (!data) { _______________________________________________ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".