Skip to content
Commit 07320c91 authored by Paul Cercueil's avatar Paul Cercueil Committed by Guenter Roeck
Browse files

hwmon: Fix possible NULL pointer



The recent addition of the label attribute added some code that read the
"label" device property, without checking first that "dev" was non-NULL.

Fix this issue by first checking that "dev" is non-NULL.

Fixes: ccd98cba6a18 ("hwmon: Add "label" attribute")
Signed-off-by: default avatarPaul Cercueil <paul@crapouillou.net>
Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
parent 9f93aa10
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