[FFmpeg-cvslog] avformat/id3v2: fix leak in chapter parsing

Fredrik Hubinette git at videolan.org
Thu Oct 26 23:29:58 EEST 2017


ffmpeg | branch: release/3.2 | Fredrik Hubinette <hubbe at google.com> | Tue Feb  7 12:19:38 2017 -0800| [b76dcd07868ecd260b5ed6baa20a1cf1788c10d3] | committer: Michael Niedermayer

avformat/id3v2: fix leak in chapter parsing

Reviewed-on: https://chromium-review.googlesource.com/439405
Reviewed-by: Dale Curtis <dalecurtis at chromium.org>
Signed-off-by: James Almer <jamrial at gmail.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=b76dcd07868ecd260b5ed6baa20a1cf1788c10d3
---

 libavformat/id3v2.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavformat/id3v2.c b/libavformat/id3v2.c
index 9969d7a6ca..85a31f77f2 100644
--- a/libavformat/id3v2.c
+++ b/libavformat/id3v2.c
@@ -688,9 +688,9 @@ static void read_chapter(AVFormatContext *s, AVIOContext *pb, int len, const cha
     }
 
     if (decode_str(s, pb, 0, &dst, &len) < 0)
-        return;
+        goto end;
     if (len < 16)
-        return;
+        goto end;
 
     start = avio_rb32(pb);
     end   = avio_rb32(pb);



More information about the ffmpeg-cvslog mailing list