- Don't free mbuf, passed to interface output method if the latter

returns error. In this case mbuf has already been freed. [1]
- Remove redundant declaration.

PR:		kern/78893 [1]
Submitted by:	Liang Yi [1]
Reviewed by:	sam
MFC after:	1 day
This commit is contained in:
Gleb Smirnoff 2005-03-29 13:43:09 +00:00
parent 52f6886551
commit d1a4742962
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=144301

View file

@ -594,9 +594,8 @@ ip_fastforward(struct mbuf *m)
} while ((m = m0) != NULL);
if (error) {
/* Reclaim remaining fragments */
for (; m; m = m0) {
for (m = m0; m; m = m0) {
m0 = m->m_nextpkt;
m->m_nextpkt = NULL;
m_freem(m);
}
} else