summaryrefslogtreecommitdiffstats
path: root/sys/kern/subr_autoconf.c
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>1999-04-25 22:13:34 +0000
committerpeter <peter@FreeBSD.org>1999-04-25 22:13:34 +0000
commit107cc59b3636d12d04ae2db934ee05542418eaa8 (patch)
tree5cc07dff162be55774665bf30bd401a632a482a7 /sys/kern/subr_autoconf.c
parent131007fae0e62f48dbf94e6b7401cf45f1e0a3a4 (diff)
downloadFreeBSD-src-107cc59b3636d12d04ae2db934ee05542418eaa8.zip
FreeBSD-src-107cc59b3636d12d04ae2db934ee05542418eaa8.tar.gz
Fix a very long standing bug in run_interrupt_driven_config_hooks(). It
was fetching the next pointer from memory that could have been free()'d.
Diffstat (limited to 'sys/kern/subr_autoconf.c')
-rw-r--r--sys/kern/subr_autoconf.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/kern/subr_autoconf.c b/sys/kern/subr_autoconf.c
index 2199134..3e90dc5 100644
--- a/sys/kern/subr_autoconf.c
+++ b/sys/kern/subr_autoconf.c
@@ -41,7 +41,7 @@
*
* @(#)subr_autoconf.c 8.1 (Berkeley) 6/10/93
*
- * $Id: subr_autoconf.c,v 1.9 1999/04/17 08:36:04 peter Exp $
+ * $Id: subr_autoconf.c,v 1.10 1999/04/17 09:12:35 peter Exp $
*/
#include <sys/param.h>
@@ -66,10 +66,11 @@ static void
run_interrupt_driven_config_hooks(dummy)
void *dummy;
{
- struct intr_config_hook *hook;
+ struct intr_config_hook *hook, *next;
for (hook = intr_config_hook_list.tqh_first; hook != NULL;
- hook = hook->ich_links.tqe_next) {
+ hook = next) {
+ next = hook->ich_links.tqe_next;
(*hook->ich_func)(hook->ich_arg);
}
OpenPOWER on IntegriCloud