lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  PHC 
Open Source and information security mailing list archives
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 15 Apr 2008 15:43:54 -0400
From:	Allan Stephens <>
To:	David Miller <>
Subject: [PATCH 4/7 net-2.6.26] [TIPC]: Remove redundant NULL check when discarding buffers

This patch eliminates a null pointer check when discarding a
TIPC message buffer, since kfree_skb() already handles this

Acknowledgements to Florian Westphal (> for
suggesting this enhancement.

Signed-off-by: Allan Stephens <>
 net/tipc/core.h |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/net/tipc/core.h b/net/tipc/core.h
index 3fe9b70..3229d29 100644
--- a/net/tipc/core.h
+++ b/net/tipc/core.h
@@ -334,8 +334,7 @@ static inline struct sk_buff *buf_acquire(u32 size)
 static inline void buf_discard(struct sk_buff *skb)
-	if (likely(skb != NULL))
-		kfree_skb(skb);
+	kfree_skb(skb);

To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to
More majordomo info at

Powered by blists - more mailing lists