Browse Source

avformat/matroskaenc: Fix memleak upon encountering bogus chapter

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
(cherry picked from commit cb255b616c)
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
release/3.2
Andreas Rheinhardt 5 years ago
parent
commit
852e1978e4
1 changed files with 1 additions and 0 deletions
  1. +1
    -0
      libavformat/matroskaenc.c

+ 1
- 0
libavformat/matroskaenc.c View File

@@ -1319,6 +1319,7 @@ static int mkv_write_chapters(AVFormatContext *s)
av_log(s, AV_LOG_ERROR,
"Invalid chapter start (%"PRId64") or end (%"PRId64").\n",
chapterstart, chapterend);
ffio_free_dyn_buf(&dyn_cp);
return AVERROR_INVALIDDATA;
}



Loading…
Cancel
Save