Avoid use of freed memory. Reported by Ted Unangst on tech-kern.

This commit is contained in:
martin 2005-02-24 08:29:23 +00:00
parent 2ec706cc8a
commit 7719036ed6
1 changed files with 3 additions and 2 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: tp_timer.c,v 1.15 2004/04/19 05:16:46 matt Exp $ */
/* $NetBSD: tp_timer.c,v 1.16 2005/02/24 08:29:23 martin Exp $ */
/*-
* Copyright (c) 1991, 1993
@ -59,7 +59,7 @@ SOFTWARE.
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: tp_timer.c,v 1.15 2004/04/19 05:16:46 matt Exp $");
__KERNEL_RCSID(0, "$NetBSD: tp_timer.c,v 1.16 2005/02/24 08:29:23 martin Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -221,6 +221,7 @@ tp_slowtimo(void)
}
/* XXX wart; where else to do it? */
free((caddr_t) tpcb, M_PCB);
break;
}
}
}