Don't leak memory in an error case.
MFC after: 1 week
This commit is contained in:
parent
59713bbf27
commit
6fb9db98b3
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=287457
@ -11235,6 +11235,11 @@ sctp_send_hb(struct sctp_tcb *stcb, struct sctp_nets *net, int so_locked
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
if (chk->data) {
|
||||
sctp_m_freem(chk->data);
|
||||
chk->data = NULL;
|
||||
}
|
||||
sctp_free_a_chunk(stcb, chk, so_locked);
|
||||
return;
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user