Free our input mbuf when the FCS is good (oops, memory leak).
This commit is contained in:
parent
07d18a334d
commit
f2896d69aa
@ -26,7 +26,7 @@
|
|||||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||||
* SUCH DAMAGE.
|
* SUCH DAMAGE.
|
||||||
*
|
*
|
||||||
* $Id$
|
* $Id: pred.c,v 1.19 1997/12/21 12:11:08 brian Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <sys/param.h>
|
#include <sys/param.h>
|
||||||
@ -279,6 +279,7 @@ Pred1Input(u_short *proto, struct mbuf *bp)
|
|||||||
wp->cnt -= 2;
|
wp->cnt -= 2;
|
||||||
*proto = (*proto << 8) | *pp++;
|
*proto = (*proto << 8) | *pp++;
|
||||||
}
|
}
|
||||||
|
pfree(bp);
|
||||||
return wp;
|
return wp;
|
||||||
} else {
|
} else {
|
||||||
LogDumpBp(LogHDLC, "Bad FCS", wp);
|
LogDumpBp(LogHDLC, "Bad FCS", wp);
|
||||||
|
Loading…
Reference in New Issue
Block a user