From 6d97175e92d7567d3eb5ec830b717d4c40e7ed8f Mon Sep 17 00:00:00 2001 From: James Almer Date: Wed, 29 Jul 2026 21:45:37 -0300 Subject: [PATCH] avcodec/bsf/eac3_core: clear profile value on init() The output stream no longer has Atmos metadata, so the AV_PROFILE_EAC3_DDP_ATMOS profile, if it was set, is no longer valid. Signed-off-by: James Almer (cherry picked from commit c77c0e580a39580c085b7182885601015b7f3da4) --- libavcodec/bsf/eac3_core.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/libavcodec/bsf/eac3_core.c b/libavcodec/bsf/eac3_core.c index 1c714b18f9..40d8cb09cf 100644 --- a/libavcodec/bsf/eac3_core.c +++ b/libavcodec/bsf/eac3_core.c @@ -23,6 +23,13 @@ #include "get_bits.h" #include "ac3_parser_internal.h" +static int eac3_core_init(AVBSFContext *ctx) +{ + ctx->par_out->profile = AV_PROFILE_UNKNOWN; + + return 0; +} + static int eac3_core_filter(AVBSFContext *ctx, AVPacket *pkt) { AC3HeaderInfo hdr; @@ -82,5 +89,6 @@ static const enum AVCodecID codec_ids[] = { const FFBitStreamFilter ff_eac3_core_bsf = { .p.name = "eac3_core", .p.codec_ids = codec_ids, + .init = eac3_core_init, .filter = eac3_core_filter, };