diff --git a/libavcodec/nvdec.c b/libavcodec/nvdec.c index 1c24bae8c1..caf9715707 100644 --- a/libavcodec/nvdec.c +++ b/libavcodec/nvdec.c @@ -667,6 +667,8 @@ int ff_nvdec_simple_end_frame(AVCodecContext *avctx) NVDECContext *ctx = avctx->internal->hwaccel_priv_data; int ret = ff_nvdec_end_frame(avctx); ctx->bitstream = NULL; + ctx->bitstream_len = 0; + ctx->nb_slices = 0; return ret; }