All of lore.kernel.org
 help / color / mirror / Atom feed
* [Bridge] [patch] bridge: cleanup: remove unneed check
@ 2010-03-06 11:14 ` Dan Carpenter
  0 siblings, 0 replies; 8+ messages in thread
From: Dan Carpenter @ 2010-03-06 11:14 UTC (permalink / raw)
  To: Herbert Xu; +Cc: netdev, kernel-janitors, bridge, David S. Miller

We dereference "port" on the lines immediately before and immediately 
after the test so port should hopefully never be null here.

Signed-off-by: Dan Carpenter <error27@gmail.com>

diff --git a/net/bridge/br_multicast.c b/net/bridge/br_multicast.c
index 2559fb5..8b25887 100644
--- a/net/bridge/br_multicast.c
+++ b/net/bridge/br_multicast.c
@@ -627,8 +627,8 @@ static void br_multicast_port_query_expired(unsigned long data)
 	struct net_bridge *br = port->br;
 
 	spin_lock(&br->multicast_lock);
-	if (port && (port->state == BR_STATE_DISABLED ||
-		     port->state == BR_STATE_BLOCKING))
+	if (port->state == BR_STATE_DISABLED ||
+	    port->state == BR_STATE_BLOCKING)
 		goto out;
 
 	if (port->multicast_startup_queries_sent <

^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2010-03-07 23:27 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-03-06 11:14 [Bridge] [patch] bridge: cleanup: remove unneed check Dan Carpenter
2010-03-06 11:14 ` Dan Carpenter
2010-03-06 11:14 ` Dan Carpenter
2010-03-06 12:20 ` [Bridge] " Herbert Xu
2010-03-06 12:20   ` Herbert Xu
2010-03-07 23:27   ` [Bridge] " David Miller
2010-03-07 23:27     ` David Miller
2010-03-07 23:27     ` David Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.