diff mbox series

[FFmpeg-devel,10/11] avcodec/avcodec: Simplify check for flushing of bsf

Message ID PR3PR03MB66650696A561860FE4BE069A8FA49@PR3PR03MB6665.eurprd03.prod.outlook.com
State Accepted
Commit b9fd9bce7328d8993c33f7892db3f1d58c8be18f
Headers show
Series [FFmpeg-devel,01/11] avcodec/tests/utils: Rename to avcodec
Related show


Context Check Description
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished
andriy/make_ppc success Make finished
andriy/make_fate_ppc success Make fate finished

Commit Message

Andreas Rheinhardt Sept. 24, 2021, 4:37 p.m. UTC
Just check for the existence of the bsf. This is equivalent to
the old criterion of the AVCodecContext being a decoder.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
 libavcodec/avcodec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series


diff --git a/libavcodec/avcodec.c b/libavcodec/avcodec.c
index 5d85ed234b..ff3d73e237 100644
--- a/libavcodec/avcodec.c
+++ b/libavcodec/avcodec.c
@@ -418,7 +418,7 @@  void avcodec_flush_buffers(AVCodecContext *avctx)
     avctx->pts_correction_last_pts =
     avctx->pts_correction_last_dts = INT64_MIN;
-    if (av_codec_is_decoder(avctx->codec))
+    if (avci->bsf)