diff options
author | Markus Elfring | 2019-08-21 20:10:56 +0200 |
---|---|---|
committer | David S. Miller | 2019-08-22 16:22:03 -0700 |
commit | 0f817a5eb9e33cec5baf9dc265bdf240b03cf51b (patch) | |
tree | 356976032586241d3c12d7b1172a1bc0b2a6aeb2 /drivers/isdn/mISDN/stack.c | |
parent | d3ee8ec7de83abf4325c11bcd36cbd01d7a66789 (diff) |
mISDN: Delete unnecessary checks before the macro call “dev_kfree_skb”
The dev_kfree_skb() function performs also input parameter validation.
Thus the test around the shown calls is not needed.
This issue was detected by using the Coccinelle software.
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/isdn/mISDN/stack.c')
-rw-r--r-- | drivers/isdn/mISDN/stack.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/isdn/mISDN/stack.c b/drivers/isdn/mISDN/stack.c index fa2237e7bcf8..27aa32914425 100644 --- a/drivers/isdn/mISDN/stack.c +++ b/drivers/isdn/mISDN/stack.c @@ -75,8 +75,7 @@ send_socklist(struct mISDN_sock_list *sl, struct sk_buff *skb) cskb = NULL; } read_unlock(&sl->lock); - if (cskb) - dev_kfree_skb(cskb); + dev_kfree_skb(cskb); } static void @@ -134,8 +133,7 @@ send_layer2(struct mISDNstack *st, struct sk_buff *skb) } out: mutex_unlock(&st->lmutex); - if (skb) - dev_kfree_skb(skb); + dev_kfree_skb(skb); } static inline int |