avcodec/cbs_h266_syntax_template: Fix w/h typo

Fixes: out of array access
Fixes: vvc_poc_subpic_wh_bug.h266

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit 26dd9f9b56)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
Gil Portnoy
2026-03-11 04:39:06 +01:00
committed by Michael Niedermayer
parent f851191ce6
commit ca6e0ee7aa

View File

@@ -1216,7 +1216,7 @@ static int FUNC(sps)(CodedBitstreamContext *ctx, RWContext *rw,
int num_subpic_cols = tmp_width_val /
(current->sps_subpic_width_minus1[0] + 1);
if (tmp_width_val % (current->sps_subpic_width_minus1[0] + 1) ||
tmp_height_val % (current->sps_subpic_width_minus1[0] + 1) ||
tmp_height_val % (current->sps_subpic_height_minus1[0] + 1) ||
current->sps_num_subpics_minus1 !=
(num_subpic_cols * tmp_height_val /
(current->sps_subpic_height_minus1[0] + 1) - 1))