mirror of
https://github.com/opnsense/src.git
synced 2026-06-10 17:22:46 -04:00
Correct check for NULL in MEXT_INIT_REF() which should be checking whether
mbuf->m_ext.ref_cnt is NULL, and not whether mbuf is. Also, remove spaces before "mbtypes" in MGET and MGETHDR macros. Pointed out by: dwmalone
This commit is contained in:
parent
d62abc771f
commit
7ba0dcf1ae
1 changed files with 3 additions and 3 deletions
|
|
@ -320,7 +320,7 @@ struct mcntfree_lst {
|
|||
struct mbuf *__mmm = (m); \
|
||||
\
|
||||
_MEXT_ALLOC_CNT(__mmm->m_ext.ref_cnt, (how)); \
|
||||
if (__mmm != NULL) \
|
||||
if (__mmm->m_ext.ref_cnt != NULL) \
|
||||
MEXT_ADD_REF(__mmm); \
|
||||
} while (0)
|
||||
|
||||
|
|
@ -367,7 +367,7 @@ struct mcntfree_lst {
|
|||
mtx_enter(&mmbfree.m_mtx, MTX_DEF); \
|
||||
_MGET(_mm, _mhow); \
|
||||
if (_mm != NULL) { \
|
||||
mbtypes[_mtype]++; \
|
||||
mbtypes[_mtype]++; \
|
||||
mtx_exit(&mmbfree.m_mtx, MTX_DEF); \
|
||||
_MGET_SETUP(_mm, _mtype); \
|
||||
} else \
|
||||
|
|
@ -394,7 +394,7 @@ struct mcntfree_lst {
|
|||
mtx_enter(&mmbfree.m_mtx, MTX_DEF); \
|
||||
_MGET(_mm, _mhow); \
|
||||
if (_mm != NULL) { \
|
||||
mbtypes[_mtype]++; \
|
||||
mbtypes[_mtype]++; \
|
||||
mtx_exit(&mmbfree.m_mtx, MTX_DEF); \
|
||||
_MGETHDR_SETUP(_mm, _mtype); \
|
||||
} else \
|
||||
|
|
|
|||
Loading…
Reference in a new issue