PR #24516 opened by michaelni URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/24516 Patch URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/24516.patch
Fixes: NULL pointer dereference Fixes: SKtVkjDrynCQ/testcase/poc.hevc / gen.py Fixes: SKtVkjDrynCQ Regression since: 3769968afdae4b0530eef438cb6cccd243258532 Found-by: Zheng Yu @ Depthfirst >From 9abd928c90a7dc21e398a567540b87c310d7978d Mon Sep 17 00:00:00 2001 From: Michael Niedermayer <[email protected]> Date: Tue, 15 Sep 2026 06:06:52 +0200 Subject: [PATCH] fftools/ffprobe: name the film grain components and pieces Fixes: NULL pointer dereference Fixes: SKtVkjDrynCQ/testcase/poc.hevc / gen.py Fixes: SKtVkjDrynCQ Regression since: 3769968afdae4b0530eef438cb6cccd243258532 Found-by: Zheng Yu @ Depthfirst --- fftools/ffprobe.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/fftools/ffprobe.c b/fftools/ffprobe.c index cc622cfdc3..7af20b2870 100644 --- a/fftools/ffprobe.c +++ b/fftools/ffprobe.c @@ -973,6 +973,7 @@ static void print_film_grain_params(AVTextFormatContext *tfc, [AV_FILM_GRAIN_PARAMS_AV1] = "av1", [AV_FILM_GRAIN_PARAMS_H274] = "h274", }; + const char *const component_names[] = { "Y", "Cb", "Cr" }; AVBPrint pbuf; if (!fgp || fgp->type >= FF_ARRAY_ELEMS(film_grain_type_names)) @@ -1013,7 +1014,7 @@ static void print_film_grain_params(AVTextFormatContext *tfc, avtext_print_section_header(tfc, NULL, SECTION_ID_FRAME_SIDE_DATA_COMPONENT_LIST); if (aom->num_y_points) { - avtext_print_section_header(tfc, NULL, SECTION_ID_FRAME_SIDE_DATA_COMPONENT); + avtext_print_section_header(tfc, component_names[0], SECTION_ID_FRAME_SIDE_DATA_COMPONENT); print_int("bit_depth_luma", fgp->bit_depth_luma); print_list_fmt("y_points_value", "%"PRIu8, aom->num_y_points, 1, aom->y_points[idx][0]); @@ -1028,7 +1029,7 @@ static void print_film_grain_params(AVTextFormatContext *tfc, if (!aom->num_uv_points[uv] && !aom->chroma_scaling_from_luma) continue; - avtext_print_section_header(tfc, NULL, SECTION_ID_FRAME_SIDE_DATA_COMPONENT); + avtext_print_section_header(tfc, component_names[1 + uv], SECTION_ID_FRAME_SIDE_DATA_COMPONENT); print_int("bit_depth_chroma", fgp->bit_depth_chroma); print_list_fmt("uv_points_value", "%"PRIu8, aom->num_uv_points[uv], 1, aom->uv_points[uv][idx][0]); @@ -1058,13 +1059,13 @@ static void print_film_grain_params(AVTextFormatContext *tfc, if (!h274->component_model_present[c]) continue; - avtext_print_section_header(tfc, NULL, SECTION_ID_FRAME_SIDE_DATA_COMPONENT); + avtext_print_section_header(tfc, component_names[c], SECTION_ID_FRAME_SIDE_DATA_COMPONENT); print_int(c ? "bit_depth_chroma" : "bit_depth_luma", c ? fgp->bit_depth_chroma : fgp->bit_depth_luma); avtext_print_section_header(tfc, NULL, SECTION_ID_FRAME_SIDE_DATA_PIECE_LIST); for (int i = 0; i < h274->num_intensity_intervals[c]; i++) { - avtext_print_section_header(tfc, NULL, SECTION_ID_FRAME_SIDE_DATA_PIECE); + avtext_print_section_header(tfc, "Intensity interval", SECTION_ID_FRAME_SIDE_DATA_PIECE); print_int("intensity_interval_lower_bound", h274->intensity_interval_lower_bound[c][i]); print_int("intensity_interval_upper_bound", h274->intensity_interval_upper_bound[c][i]); print_list_fmt("comp_model_value", "%"PRId16, h274->num_model_values[c], 1, h274->comp_model_value[c][i][idx]); -- 2.52.0 _______________________________________________ ffmpeg-devel mailing list -- [email protected] To unsubscribe send an email to [email protected]
