Fix a double free of an SCTP association in an error path.
This is joint work with rrs@. The issue was found by running syzkaller. MFC after: 1 week
This commit is contained in:
parent
ad48359a65
commit
eb3b9ea3fe
@ -1481,8 +1481,6 @@ sctp_do_connect_x(struct socket *so, struct sctp_inpcb *inp, void *optval,
|
||||
sctp_connectx_helper_add(stcb, sa, (totaddr - 1), &error);
|
||||
/* Fill in the return id */
|
||||
if (error) {
|
||||
(void)sctp_free_assoc(inp, stcb, SCTP_PCBFREE_FORCE,
|
||||
SCTP_FROM_SCTP_USRREQ + SCTP_LOC_7);
|
||||
goto out_now;
|
||||
}
|
||||
a_id = (sctp_assoc_t *)optval;
|
||||
|
Loading…
Reference in New Issue
Block a user