diff mbox series

[FFmpeg-devel,07/13] avcodec/mpegvideo_enc: Don't set write-only properties

Message ID AS8P250MB07449C504BE274AE9FC667C88FC9A@AS8P250MB0744.EURP250.PROD.OUTLOOK.COM
State Accepted
Commit 070bc4d2c570ea823cc4586721720504d201b114
Headers show
Series [FFmpeg-devel,01/13] avcodec/mpegvideo_enc: Fix abort on allocation errors | expand

Checks

Context Check Description
yinshiyou/make_loongarch64 success Make finished
yinshiyou/make_fate_loongarch64 success Make fate finished

Commit Message

Andreas Rheinhardt Oct. 6, 2023, 2:46 a.m. UTC
The frame is immediately reset in the ff_mpeg_unref_picture()
call below.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 libavcodec/mpegvideo_enc.c | 4 ----
 1 file changed, 4 deletions(-)
diff mbox series

Patch

diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c
index c06fdd08fe..9e28304554 100644
--- a/libavcodec/mpegvideo_enc.c
+++ b/libavcodec/mpegvideo_enc.c
@@ -1698,10 +1698,6 @@  static int frame_start(MpegEncContext *s)
     }
 
     s->current_picture_ptr->f->pict_type = s->pict_type;
-    if (s->pict_type == AV_PICTURE_TYPE_I)
-        s->current_picture.f->flags |= AV_FRAME_FLAG_KEY;
-    else
-        s->current_picture.f->flags &= ~AV_FRAME_FLAG_KEY;
 
     ff_mpeg_unref_picture(s->avctx, &s->current_picture);
     if ((ret = ff_mpeg_ref_picture(s->avctx, &s->current_picture,