diff --git a/.github/workflows/build-ffmpeg.yml b/.github/workflows/build-ffmpeg.yml index 6e8953a9..638559cf 100644 --- a/.github/workflows/build-ffmpeg.yml +++ b/.github/workflows/build-ffmpeg.yml @@ -311,7 +311,6 @@ jobs: git apply -v --ignore-whitespace ../../ffmpeg_patches/ffmpeg/04-mfenc-lowlatency.patch git apply -v --ignore-whitespace ../../ffmpeg_patches/ffmpeg/05-vaapi-customized-surface-alignment.patch git apply -v --ignore-whitespace ../../ffmpeg_patches/ffmpeg/06-amfenc-query-timeout.patch - git apply -v --ignore-whitespace ../../ffmpeg_patches/ffmpeg/07-avcodec-options-revert.patch - name: Setup cross compilation id: cross diff --git a/ffmpeg_patches/ffmpeg/07-avcodec-options-revert.patch b/ffmpeg_patches/ffmpeg/07-avcodec-options-revert.patch deleted file mode 100644 index 943c4e71..00000000 --- a/ffmpeg_patches/ffmpeg/07-avcodec-options-revert.patch +++ /dev/null @@ -1,50 +0,0 @@ -From 7d7c4fc8293044a582bed30d93370ae18ac64497 Mon Sep 17 00:00:00 2001 -From: Cameron Gutman -Date: Fri, 11 Oct 2024 19:34:22 -0500 -Subject: [PATCH] Revert "lavc: Check codec_whitelist early in avcodec_open2()" - -This caused a behavior change that broke setting codec-specific options -that share names with AVCodecContext options. - -This reverts commit 7753a9d62725d5bd8313e2d249acbe1c8af79ab1. ---- - libavcodec/avcodec.c | 16 ++++++++-------- - 1 file changed, 8 insertions(+), 8 deletions(-) - -diff --git a/libavcodec/avcodec.c b/libavcodec/avcodec.c -index d1daf47611..d9b0e1246f 100644 ---- a/libavcodec/avcodec.c -+++ b/libavcodec/avcodec.c -@@ -175,14 +175,6 @@ int attribute_align_arg avcodec_open2(AVCodecContext *avctx, const AVCodec *code - if (avctx->extradata_size < 0 || avctx->extradata_size >= FF_MAX_EXTRADATA_SIZE) - return AVERROR(EINVAL); - -- if ((ret = av_opt_set_dict(avctx, options)) < 0) -- return ret; -- -- if (avctx->codec_whitelist && av_match_list(codec->name, avctx->codec_whitelist, ',') <= 0) { -- av_log(avctx, AV_LOG_ERROR, "Codec (%s) not on whitelist \'%s\'\n", codec->name, avctx->codec_whitelist); -- return AVERROR(EINVAL); -- } -- - avci = av_codec_is_decoder(codec) ? - ff_decode_internal_alloc() : - ff_encode_internal_alloc(); -@@ -216,6 +208,14 @@ int attribute_align_arg avcodec_open2(AVCodecContext *avctx, const AVCodec *code - } else { - avctx->priv_data = NULL; - } -+ if ((ret = av_opt_set_dict(avctx, options)) < 0) -+ goto free_and_end; -+ -+ if (avctx->codec_whitelist && av_match_list(codec->name, avctx->codec_whitelist, ',') <= 0) { -+ av_log(avctx, AV_LOG_ERROR, "Codec (%s) not on whitelist \'%s\'\n", codec->name, avctx->codec_whitelist); -+ ret = AVERROR(EINVAL); -+ goto free_and_end; -+ } - - // only call ff_set_dimensions() for non H.264/VP6F/DXV codecs so as not to overwrite previously setup dimensions - if (!(avctx->coded_width && avctx->coded_height && avctx->width && avctx->height && --- -2.43.0.windows.1 - diff --git a/ffmpeg_sources/ffmpeg b/ffmpeg_sources/ffmpeg index 63f5c007..87ccf995 160000 --- a/ffmpeg_sources/ffmpeg +++ b/ffmpeg_sources/ffmpeg @@ -1 +1 @@ -Subproject commit 63f5c007a7da69248f664c988398204c21eac7cf +Subproject commit 87ccf995cb855f0baced9916928b7b48d8b6ed9d