Signed-off-by: James Almer <[email protected]>
---
libavcodec/vp9_superframe_split_bsf.c | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/libavcodec/vp9_superframe_split_bsf.c
b/libavcodec/vp9_superframe_split_bsf.c
index 4e635a307..4e6e7ff08 100644
--- a/libavcodec/vp9_superframe_split_bsf.c
+++ b/libavcodec/vp9_superframe_split_bsf.c
@@ -131,6 +131,14 @@ fail:
return ret;
}
+static void vp9_superframe_split_flush(AVBSFContext *ctx)
+{
+ VP9SFSplitContext *s = ctx->priv_data;
+
+ av_packet_free(&s->buffer_pkt);
+ memset(s, 0, sizeof(*s));
+}
+
static void vp9_superframe_split_uninit(AVBSFContext *ctx)
{
VP9SFSplitContext *s = ctx->priv_data;
@@ -142,5 +150,6 @@ const AVBitStreamFilter ff_vp9_superframe_split_bsf = {
.priv_data_size = sizeof(VP9SFSplitContext),
.close = vp9_superframe_split_uninit,
.filter = vp9_superframe_split_filter,
+ .flush = vp9_superframe_split_flush,
.codec_ids = (const enum AVCodecID []){ AV_CODEC_ID_VP9,
AV_CODEC_ID_NONE },
};
--
2.18.0
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel