Remove unneded check. No need to do m_pullup to the size that we prepended.
MFC after: 1 week Sponsored by: Yandex LLC
This commit is contained in:
parent
bd766f3425
commit
2dfcd0ae9d
@ -482,8 +482,6 @@ stf_output(struct ifnet *ifp, struct mbuf *m, const struct sockaddr *dst,
|
||||
}
|
||||
|
||||
M_PREPEND(m, sizeof(struct ip), M_NOWAIT);
|
||||
if (m && m->m_len < sizeof(struct ip))
|
||||
m = m_pullup(m, sizeof(struct ip));
|
||||
if (m == NULL) {
|
||||
if_inc_counter(ifp, IFCOUNTER_OERRORS, 1);
|
||||
return ENOBUFS;
|
||||
|
@ -363,8 +363,6 @@ icmp6_error(struct mbuf *m, int type, int code, int param)
|
||||
|
||||
preplen = sizeof(struct ip6_hdr) + sizeof(struct icmp6_hdr);
|
||||
M_PREPEND(m, preplen, M_NOWAIT); /* FIB is also copied over. */
|
||||
if (m && m->m_len < preplen)
|
||||
m = m_pullup(m, preplen);
|
||||
if (m == NULL) {
|
||||
nd6log((LOG_DEBUG, "ENOBUFS in icmp6_error %d\n", __LINE__));
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user