summaryrefslogtreecommitdiff
path: root/scripts/Makefile.thinlto
diff options
context:
space:
mode:
authorHaotian Zhang <vulab@iscas.ac.cn>2026-09-01 10:23:09 +0800
committerHans Verkuil <hverkuil+cisco@kernel.org>2026-09-07 09:01:05 +0200
commit10e59fbdef13597836bd6459095caa02c80af3d7 (patch)
treef19099acd86fbd1b21ce84a22ef7c74c569e2a99 /scripts/Makefile.thinlto
parente04ffff543db06308a8100f6aa3a65aebcd9834c (diff)
downloadlinux-10e59fbdef13597836bd6459095caa02c80af3d7.tar.gz
linux-10e59fbdef13597836bd6459095caa02c80af3d7.zip
media: v4l2-h264: Fix memcmp() size in B1 reference list comparison
In v4l2_h264_build_b_ref_lists(), the B0/B1 list equality check passes the entry count builder->num_valid to memcmp() instead of a byte size. Since struct v4l2_h264_reference is two bytes (fields and index), only half of each list is compared, so distinct lists can be wrongly treated as equal and trigger an incorrect swap(b1_reflist[0], b1_reflist[1]). Change the memcmp() size argument to sizeof(b1_reflist[0]) * builder->num_valid so that the full byte length of both reference lists is compared. Fixes: 624922a2739b ("media: v4l2-core: Add helpers to build the H264 P/B0/B1 reflists") Suggested-by: Nicolas Dufresne <nicolas@ndufresne.ca> Cc: stable@vger.kernel.org Signed-off-by: Haotian Zhang <vulab@iscas.ac.cn> Reviewed-by: Nicolas Dufresne <nicolas.dufresne@collabora.com> Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>
Diffstat (limited to 'scripts/Makefile.thinlto')
0 files changed, 0 insertions, 0 deletions