diff mbox series

[FFmpeg-devel,16/39] avcodec/mpeg12dec: Remove redundant writes

Message ID 20201210111657.2276739-17-andreas.rheinhardt@gmail.com
State Accepted
Commit 1f9ef2f3cf0812c9ad3e3055946673375c982cac
Headers show
Series Make mpegvideo encoders init-threadsafe
Related show

Checks

Context Check Description
andriy/x86_make success Make finished
andriy/x86_make_fate success Make fate finished

Commit Message

Andreas Rheinhardt Dec. 10, 2020, 11:16 a.m. UTC
ff_mpv_decode_init() already sets MpegEncContext.avctx.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
---
 libavcodec/mpeg12dec.c | 3 ---
 1 file changed, 3 deletions(-)

Comments

Anton Khirnov Jan. 18, 2021, 8:53 a.m. UTC | #1
Quoting Andreas Rheinhardt (2020-12-10 12:16:34)
> ff_mpv_decode_init() already sets MpegEncContext.avctx.
> 
> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
> ---
>  libavcodec/mpeg12dec.c | 3 ---
>  1 file changed, 3 deletions(-)

Ok
diff mbox series

Patch

diff --git a/libavcodec/mpeg12dec.c b/libavcodec/mpeg12dec.c
index 123ede4704..a7980eeda7 100644
--- a/libavcodec/mpeg12dec.c
+++ b/libavcodec/mpeg12dec.c
@@ -1055,8 +1055,6 @@  static av_cold int mpeg_decode_init(AVCodecContext *avctx)
         avctx->coded_width = avctx->coded_height = 0; // do not trust dimensions from input
     ff_mpv_decode_init(s2, avctx);
 
-    s->mpeg_enc_ctx.avctx  = avctx;
-
     /* we need some permutation to store matrices,
      * until the decoder sets the real permutation. */
     ff_mpv_idct_init(s2);
@@ -3098,7 +3096,6 @@  static av_cold int ipu_decode_init(AVCodecContext *avctx)
     avctx->pix_fmt = AV_PIX_FMT_YUV420P;
 
     ff_mpv_decode_init(m, avctx);
-    s->m.avctx = avctx;
     ff_mpv_idct_init(m);
     ff_mpeg12_common_init(m);
     ff_mpeg12_init_vlcs();