Skip to content

Commit

Permalink
[media] hackrf: fix possible null ptr on debug printing
Browse files Browse the repository at this point in the history
drivers/media/usb/hackrf/hackrf.c:1533 hackrf_probe()
error: we previously assumed 'dev' could be null (see line 1366)

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
  • Loading branch information
Antti Palosaari authored and Mauro Carvalho Chehab committed Dec 18, 2015
1 parent dfcf36d commit eb35cf4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/media/usb/hackrf/hackrf.c
Original file line number Diff line number Diff line change
Expand Up @@ -1530,7 +1530,7 @@ static int hackrf_probe(struct usb_interface *intf,
err_kfree:
kfree(dev);
err:
dev_dbg(dev->dev, "failed=%d\n", ret);
dev_dbg(&intf->dev, "failed=%d\n", ret);
return ret;
}

Expand Down

0 comments on commit eb35cf4

Please sign in to comment.