diff --git a/src/filter_realcugan.cpp b/src/filter_realcugan.cpp index 37efd7e..9bde037 100644 --- a/src/filter_realcugan.cpp +++ b/src/filter_realcugan.cpp @@ -33,6 +33,7 @@ FilterRealcugan::FilterRealcugan( FilterRealcugan::~FilterRealcugan() { delete realcugan_; + realcugan_ = nullptr; } int FilterRealcugan::init(AVCodecContext* dec_ctx, AVCodecContext* enc_ctx, AVBufferRef*) { diff --git a/src/filter_realesrgan.cpp b/src/filter_realesrgan.cpp index 9b5ce7f..389f726 100644 --- a/src/filter_realesrgan.cpp +++ b/src/filter_realesrgan.cpp @@ -27,6 +27,7 @@ FilterRealesrgan::FilterRealesrgan( FilterRealesrgan::~FilterRealesrgan() { delete realesrgan_; + realesrgan_ = nullptr; } int FilterRealesrgan::init(AVCodecContext* dec_ctx, AVCodecContext* enc_ctx, AVBufferRef*) { diff --git a/src/interpolator_rife.cpp b/src/interpolator_rife.cpp index 08ac3c4..2c0f28f 100644 --- a/src/interpolator_rife.cpp +++ b/src/interpolator_rife.cpp @@ -30,6 +30,7 @@ InterpolatorRIFE::InterpolatorRIFE( InterpolatorRIFE::~InterpolatorRIFE() { delete rife_; + rife_ = nullptr; } int InterpolatorRIFE::init(AVCodecContext* dec_ctx, AVCodecContext* enc_ctx, AVBufferRef*) {