Skip to content
Commit 151f72f4 authored by Colin Ian King's avatar Colin Ian King Committed by Philipp Zabel
Browse files

reset: fix null pointer dereference on dev by dev_name



The call to dev_name will dereference dev, however, dev is later
being null checked, so there is a possibility of a null pointer
dereference on dev by the call to dev_name. Fix this by null
checking dev first before the call to dev_name

Detected by CoverityScan, CID#1475475 ("Dereference before null check")

Fixes: 2a6cb2b1d83b ("reset: Add reset_control_get_count()")
Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
Signed-off-by: default avatarPhilipp Zabel <p.zabel@pengutronix.de>
parent eaf91db0
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