Skip to content
Commit 6561e82d authored by Meghana Madhyastha's avatar Meghana Madhyastha Committed by Greg Kroah-Hartman
Browse files

Staging: irda: drivers: Replace (skb == NULL) with (!skb)



Some functions return NULL as an indication of failure.
The style (!skb) is more common than (skb == NULL) for these
functions.

Found by the following Coccinelle script.

@@
identifier i;
statement S;
@@

i = (\(kmalloc\|devm_kzalloc\|kmalloc_array\|devm_ioremap\|usb_alloc_urb\|
alloc_netdev\|dev_alloc_skb\)(...));

(
-if (i == NULL)
+if (!i)
S
|
-if (NULL == i)
+if (!i)
S
)

Signed-off-by: default avatarMeghana Madhyastha <meghana.madhyastha@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent b351fa3c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment