mirror of
https://github.com/freebsd/freebsd-src
synced 2024-09-06 17:18:32 +00:00
netgraph/ng_checksum: Fix double free error
m_pullup(9) frees the mbuf(9) chain in the case of an allocation error. The mbuf chain must not be freed again in this case. PR: 255874 Submitted by: <lylgood@foxmail.com> Approved by: markj MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D30273
This commit is contained in:
parent
8252fe56a0
commit
687e510e5c
|
@ -682,9 +682,9 @@ ng_checksum_rcvdata(hook_p hook, item_p item)
|
|||
return (error);
|
||||
|
||||
done:
|
||||
NG_FREE_M(m);
|
||||
drop:
|
||||
NG_FREE_ITEM(item);
|
||||
NG_FREE_M(m);
|
||||
|
||||
priv->stats.dropped++;
|
||||
|
||||
|
|
Loading…
Reference in a new issue