diff mbox series

[FFmpeg-devel,1/4] avfilter/vf_spp: Remove unused AVCodecContext

Message ID 20200418223747.1211-1-michael@niedermayer.cc
State Accepted
Commit dde86d0ddfa2697e2519ce2b0a4d918fa11691b5
Headers show
Series [FFmpeg-devel,1/4] avfilter/vf_spp: Remove unused AVCodecContext | expand

Checks

Context Check Description
andriy/default pending
andriy/make success Make finished
andriy/make_fate success Make fate finished

Commit Message

Michael Niedermayer April 18, 2020, 10:37 p.m. UTC
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
---
 libavfilter/vf_spp.c | 7 +------
 libavfilter/vf_spp.h | 2 --
 2 files changed, 1 insertion(+), 8 deletions(-)

Comments

Michael Niedermayer May 11, 2020, 10:57 p.m. UTC | #1
On Sun, Apr 19, 2020 at 12:37:44AM +0200, Michael Niedermayer wrote:
> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
> ---
>  libavfilter/vf_spp.c | 7 +------
>  libavfilter/vf_spp.h | 2 --
>  2 files changed, 1 insertion(+), 8 deletions(-)

will apply patchset

[...]
diff mbox series

Patch

diff --git a/libavfilter/vf_spp.c b/libavfilter/vf_spp.c
index 7381938f7f..1b934aa9d7 100644
--- a/libavfilter/vf_spp.c
+++ b/libavfilter/vf_spp.c
@@ -460,9 +460,8 @@  static av_cold int init_dict(AVFilterContext *ctx, AVDictionary **opts)
     SPPContext *s = ctx->priv;
     int ret;
 
-    s->avctx = avcodec_alloc_context3(NULL);
     s->dct = avcodec_dct_alloc();
-    if (!s->avctx || !s->dct)
+    if (!s->dct)
         return AVERROR(ENOMEM);
 
     if (opts) {
@@ -489,10 +488,6 @@  static av_cold void uninit(AVFilterContext *ctx)
 
     av_freep(&s->temp);
     av_freep(&s->src);
-    if (s->avctx) {
-        avcodec_close(s->avctx);
-        av_freep(&s->avctx);
-    }
     av_freep(&s->dct);
     av_freep(&s->non_b_qp_table);
 }
diff --git a/libavfilter/vf_spp.h b/libavfilter/vf_spp.h
index c03073a4e1..879ed40f03 100644
--- a/libavfilter/vf_spp.h
+++ b/libavfilter/vf_spp.h
@@ -22,7 +22,6 @@ 
 #ifndef AVFILTER_SPP_H
 #define AVFILTER_SPP_H
 
-#include "libavcodec/avcodec.h"
 #include "libavcodec/avdct.h"
 #include "avfilter.h"
 
@@ -38,7 +37,6 @@  typedef struct SPPContext {
     int temp_linesize;
     uint8_t *src;
     uint16_t *temp;
-    AVCodecContext *avctx;
     AVDCT *dct;
     int8_t *non_b_qp_table;
     int non_b_qp_alloc_size;