projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d726c01
)
can: dev: can_restart(): convert NULL pointer check
author
Marc Kleine-Budde
<mkl@pengutronix.de>
Tue, 27 Aug 2019 19:11:17 +0000
(21:11 +0200)
committer
Marc Kleine-Budde
<mkl@pengutronix.de>
Tue, 3 Sep 2019 08:28:13 +0000
(10:28 +0200)
This patch converts the NULL pointer check in can_restart() form "skb ==
NULL" to "!skb".
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
drivers/net/can/dev.c
patch
|
blob
|
history
diff --git
a/drivers/net/can/dev.c
b/drivers/net/can/dev.c
index c80d32c048334ddad97baebd19a485c13bf4ddfa..0d18a719ded981424e6f4095a101ef7e0f9ff6ac 100644
(file)
--- a/
drivers/net/can/dev.c
+++ b/
drivers/net/can/dev.c
@@
-552,7
+552,7
@@
static void can_restart(struct net_device *dev)
/* send restart message upstream */
skb = alloc_can_err_skb(dev, &cf);
- if (
skb == NULL
) {
+ if (
!skb
) {
err = -ENOMEM;
goto restart;
}