diff options
author | Michael Niedermayer <michael@niedermayer.cc> | 2019-10-31 13:32:55 +0100 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2020-01-06 11:30:44 +0100 |
commit | 3b8512ae09f7552fce1d7896af8d52ce36be8520 (patch) | |
tree | f29b6f3ee915c26826ad0b524d25e4fcf7d090dd | |
parent | ad3c8540f877f0eee8a1561c42a582c8fed822d8 (diff) | |
download | ffmpeg-3b8512ae09f7552fce1d7896af8d52ce36be8520.tar.gz |
avformat/mxfdec: Clear metadata_sets_count in mxf_read_close()
This avoids problems if the function is called twice
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit 13816a1d085fdb6598ea6dc92ed3a1e6aff0cc1f)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r-- | libavformat/mxfdec.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/libavformat/mxfdec.c b/libavformat/mxfdec.c index f49890e140..c3ee7617f9 100644 --- a/libavformat/mxfdec.c +++ b/libavformat/mxfdec.c @@ -3542,6 +3542,7 @@ static int mxf_read_close(AVFormatContext *s) for (i = 0; i < mxf->metadata_sets_count; i++) { mxf_free_metadataset(mxf->metadata_sets + i, 1); } + mxf->metadata_sets_count = 0; av_freep(&mxf->partitions); av_freep(&mxf->metadata_sets); av_freep(&mxf->aesc); |