diff options
author | Markus Elfring <elfring@users.sourceforge.net> | 2017-08-28 12:50:28 +0200 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@s-opensource.com> | 2017-09-23 14:20:57 +0200 |
commit | af28c99628ebfbdc3fff3d92c7044d3a51b7ccea (patch) | |
tree | ff56a13fbd5ed6c2bb20a746464fd49fb0199c48 /drivers/media/dvb-frontends/sp2.c | |
parent | media: drivers: improve a size determination (diff) | |
download | linux-af28c99628ebfbdc3fff3d92c7044d3a51b7ccea.tar.xz linux-af28c99628ebfbdc3fff3d92c7044d3a51b7ccea.zip |
media: drivers: Adjust checks for null pointers
The script “checkpatch.pl” pointed information out like the following.
Comparison to NULL could be written !…
Thus fix the affected source code places.
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: Hans Verkuil <hansverk@cisco.com>
Diffstat (limited to 'drivers/media/dvb-frontends/sp2.c')
-rw-r--r-- | drivers/media/dvb-frontends/sp2.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/media/dvb-frontends/sp2.c b/drivers/media/dvb-frontends/sp2.c index dd556012ceb6..53e66c232d3c 100644 --- a/drivers/media/dvb-frontends/sp2.c +++ b/drivers/media/dvb-frontends/sp2.c @@ -357,14 +357,14 @@ static int sp2_exit(struct i2c_client *client) dev_dbg(&client->dev, "\n"); - if (client == NULL) + if (!client) return 0; s = i2c_get_clientdata(client); - if (s == NULL) + if (!s) return 0; - if (s->ca.data == NULL) + if (!s->ca.data) return 0; dvb_ca_en50221_release(&s->ca); |