diff --git a/libavformat/mov.c b/libavformat/mov.c index d1b29a2211..d24faa7b18 100644 --- a/libavformat/mov.c +++ b/libavformat/mov.c @@ -3973,6 +3973,9 @@ static int mov_read_close(AVFormatContext *s) AVStream *st = s->streams[i]; MOVStreamContext *sc = st->priv_data; + if (!sc) + continue; + av_freep(&sc->ctts_data); for (j = 0; j < sc->drefs_count; j++) { av_freep(&sc->drefs[j].path);