Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit b4c21f0b authored by Kishon Vijay Abraham I's avatar Kishon Vijay Abraham I Committed by Felipe Balbi
Browse files

usb: gadget: composite: Fix NULL pointer dereference



commit f563d230 ("usb: gadget: composite: add req_match method
to usb_function") accesses cdev->config even before set config
is invoked causing a NULL pointer dereferencing error while running
Lecroy Mass Storage Compliance test.

Fix it here by accessing cdev->config only if it is non NULL.

Fixes: commit f563d230 ("usb: gadget: composite: add req_match
method to usb_function").

Signed-off-by: default avatarKishon Vijay Abraham I <kishon@ti.com>
Signed-off-by: default avatarFelipe Balbi <balbi@ti.com>
parent 4088acf1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment