Skip to contentSkip to conversation

sctp: fix bogus if statement in sctp_auth_recv_cid()

PATCH Applied Dan Carpenter 3 participants 3 messages Aug 16, 2012

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 sctp: fix bogus if statement in sctp_auth_recv_cid()

There is an extra semi-colon here, so we always return 0 instead of calling __sctp_auth_cid().

---
Only needed for linux-next.

net/sctp/auth.c +1 -1
index aaa6c12..159b9bc 100644
@@ -695,7 +695,7 @@ int sctp_auth_recv_cid(sctp_cid_t chunk, const struct sctp_association *asoc)
 		return 0;
 
 	net = sock_net(asoc->base.sk);
-	if (!net->sctp.auth_enable);
+	if (!net->sctp.auth_enable)
 		return 0;
 
 	return __sctp_auth_cid(chunk,
Reviewed-by on v1 1/1
#1 lore raw
Quoted 2 lines · Dan Carpenter

There is an extra semi-colon here, so we always return 0 instead of calling __sctp_auth_cid().

Doh.

Quoted 18 lines

---
Only needed for linux-next.

net/sctp/auth.c +1 -1
index aaa6c12..159b9bc 100644
@@ -695,7 +695,7 @@ int sctp_auth_recv_cid(sctp_cid_t chunk, const struct sctp_association *asoc)
 		return 0;
 
 	net = sock_net(asoc->base.sk);
-	if (!net->sctp.auth_enable);
+	if (!net->sctp.auth_enable)
 		return 0;
 
 	return __sctp_auth_cid(chunk,