diff options
Diffstat (limited to 'sys/netgraph/ng_lmi.c')
-rw-r--r-- | sys/netgraph/ng_lmi.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/netgraph/ng_lmi.c b/sys/netgraph/ng_lmi.c index a404998..239bc57 100644 --- a/sys/netgraph/ng_lmi.c +++ b/sys/netgraph/ng_lmi.c @@ -577,8 +577,9 @@ nglmi_rcvdata(hook_p hook, struct mbuf *m, meta_p meta) log(LOG_WARNING, "nglmi: packetlen (%d) too big\n", packetlen); goto drop; } - if ((m = m_pullup(m, packetlen)) == NULL) { - log(LOG_WARNING, "nglmi: m_pullup failed for %d bytes\n", packetlen); + if (m->m_len < packetlen && (m = m_pullup(m, packetlen)) == NULL) { + log(LOG_WARNING, + "nglmi: m_pullup failed for %d bytes\n", packetlen); NG_FREE_META(meta); return (0); } |