]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commit
media: gspca/sq905.c: fix uninitialized variable
authorHans Verkuil <hverkuil-cisco@xs4all.nl>
Thu, 11 Mar 2021 14:46:40 +0000 (15:46 +0100)
committerStefan Bader <stefan.bader@canonical.com>
Wed, 19 May 2021 08:59:40 +0000 (10:59 +0200)
commitea20894ce487aacf0ec4d69d27018ffc732fae3f
treef97f61b7f9a51458dbf94737e8fcc99e3077f1ad
parent53be7c85f12933d13563c8527d9b87c5ee9efc6d
media: gspca/sq905.c: fix uninitialized variable

BugLink: https://bugs.launchpad.net/bugs/1928825
[ Upstream commit eaaea4681984c79d2b2b160387b297477f0c1aab ]

act_len can be uninitialized if usb_bulk_msg() returns an error.
Set it to 0 to avoid a KMSAN error.

Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Reported-by: syzbot+a4e309017a5f3a24c7b3@syzkaller.appspotmail.com
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
drivers/media/usb/gspca/sq905.c