Fix leak of frame_duration_buffer in mov_fix_index().
authorDale Curtis <dalecurtis@chromium.org>
Fri, 17 Nov 2017 22:53:25 +0000 (14:53 -0800)
committerMichael Niedermayer <michael@niedermayer.cc>
Thu, 7 Dec 2017 22:38:06 +0000 (23:38 +0100)
Should be unconditionally freed at the end of mov_fix_index() in
case it hasn't been used during the fix up.

Signed-off-by: Dale Curtis <dalecurtis@chromium.org>
Reviewed-by: Sasi Inguva <isasi-at-google.com@ffmpeg.org>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit d073be2291e40129d107ca4573097d6d6d2dbf68)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
libavformat/mov.c

index 5acac07..57cef83 100644 (file)
@@ -3329,6 +3329,7 @@ static void mov_fix_index(MOVContext *mov, AVStream *st)
     // Free the old index and the old CTTS structures
     av_free(e_old);
     av_free(ctts_data_old);
+    av_freep(&frame_duration_buffer);
 
     // Null terminate the index ranges array
     current_index_range++;