Thread (8 messages) 8 messages, 3 authors, 2021-07-27

Re: [PATCH net 1/4] sctp: validate from_addr_param return

From: Ben Hutchings <hidden>
Date: 2021-07-27 02:44:47
Also in: linux-sctp

On Mon, Jun 28, 2021 at 04:13:41PM -0300, Marcelo Ricardo Leitner wrote:
[...]
quoted hunk ↗ jump to hunk
@@ -1174,7 +1175,8 @@ static struct sctp_association *__sctp_rcv_asconf_lookup(
 	if (unlikely(!af))
 		return NULL;
 
-	af->from_addr_param(&paddr, param, peer_port, 0);
+	if (af->from_addr_param(&paddr, param, peer_port, 0))
+		return NULL;
 
 	return __sctp_lookup_association(net, laddr, &paddr, transportp);
 }
[...]

This condition needs to be inverted, doesn't it?

Ben.

-- 
Ben Hutchings
friends: People who know you well, but like you anyway.

Attachments

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help