[FFmpeg-cvslog] avcodec/utils: Fix memleak on error in convert_sub_to_old_ass_form()
Michael Niedermayer
git at videolan.org
Sat Mar 5 01:51:03 CET 2016
ffmpeg | branch: master | Michael Niedermayer <michael at niedermayer.cc> | Sat Mar 5 01:38:58 2016 +0100| [dec816f92c7cf0bbb0f30c095db05145687c6100] | committer: Michael Niedermayer
avcodec/utils: Fix memleak on error in convert_sub_to_old_ass_form()
Fixes CID1355116
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=dec816f92c7cf0bbb0f30c095db05145687c6100
---
libavcodec/utils.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/libavcodec/utils.c b/libavcodec/utils.c
index b993899..bbb9804 100644
--- a/libavcodec/utils.c
+++ b/libavcodec/utils.c
@@ -2517,6 +2517,7 @@ static int convert_sub_to_old_ass_form(AVSubtitle *sub, const AVPacket *pkt, AVR
final_dialog = av_strdup(buf.str);
if (!av_bprint_is_complete(&buf) || !final_dialog) {
+ av_freep(&final_dialog);
av_bprint_finalize(&buf, NULL);
return AVERROR(ENOMEM);
}
More information about the ffmpeg-cvslog
mailing list