]> www.infradead.org Git - users/jedix/linux-maple.git/commit
media: dvb-core: add missing buffer index check
authorHans Verkuil <hverkuil-cisco@xs4all.nl>
Tue, 1 Oct 2024 09:01:34 +0000 (11:01 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Sat, 12 Oct 2024 05:42:35 +0000 (07:42 +0200)
commitbfe703ac0c9f42fd54ec46416146f46d9502bc8c
treeffc42ade2cb7df7a5b367a3b84aa43807bf970c7
parent4115edeff98f2ce9f821a8bddcd7a646cfdde77a
media: dvb-core: add missing buffer index check

dvb_vb2_expbuf() didn't check if the given buffer index was
for a valid buffer. Add this check.

Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Reported-by: Chenyuan Yang <chenyuan0y@gmail.com>
Fixes: 7dc866df4012 ("media: dvb-core: Use vb2_get_buffer() instead of directly access to buffers array")
Reviewed-by: Benjamin Gaignard <benjamin.gaignard@collabora.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/dvb-core/dvb_vb2.c