Skip to content
Commit 2d4b310c authored by Anastasia Belova's avatar Anastasia Belova Committed by Greg Kroah-Hartman
Browse files

HID: hid-lg4ff: Add check for empty lbuf

commit d180b649 upstream.

If an empty buf is received, lbuf is also empty. So lbuf is
accessed by index -1.

Found by Linux Verification Center (linuxtesting.org) with SVACE.

Fixes: f31a2de3

 ("HID: hid-lg4ff: Allow switching of Logitech gaming wheels between compatibility modes")
Signed-off-by: default avatarAnastasia Belova <abelova@astralinux.ru>
Signed-off-by: default avatarJiri Kosina <jkosina@suse.cz>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 5e8021ae
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment