mirror of
https://github.com/freebsd/freebsd-src
synced 2024-10-16 21:34:10 +00:00
Do not leak lro_hash on failure to allocate lro_mbuf_data.
MFC after: 1 week
This commit is contained in:
parent
5971d9cf1c
commit
a3927369fa
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=317172
|
@ -144,6 +144,7 @@ tcp_lro_init_args(struct lro_ctrl *lc, struct ifnet *ifp,
|
|||
|
||||
/* check for out of memory */
|
||||
if (lc->lro_mbuf_data == NULL) {
|
||||
free(lc->lro_hash, M_LRO);
|
||||
memset(lc, 0, sizeof(*lc));
|
||||
return (ENOMEM);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue