diff options
Diffstat (limited to 'sys/kern/kern_alq.c')
-rw-r--r-- | sys/kern/kern_alq.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/kern/kern_alq.c b/sys/kern/kern_alq.c index daf4e46..1e6fcf7 100644 --- a/sys/kern/kern_alq.c +++ b/sys/kern/kern_alq.c @@ -229,8 +229,6 @@ ald_shutdown(void *arg, int howto) { struct alq *alq; - EVENTHANDLER_DEREGISTER(shutdown_pre_sync, alq_eventhandler_tag); - ALD_LOCK(); /* Ensure no new queues can be created. */ @@ -938,6 +936,8 @@ alq_load_handler(module_t mod, int what, void *arg) if (LIST_FIRST(&ald_queues) == NULL) { ald_shutingdown = 1; ALD_UNLOCK(); + EVENTHANDLER_DEREGISTER(shutdown_pre_sync, + alq_eventhandler_tag); ald_shutdown(NULL, 0); mtx_destroy(&ald_mtx); } else { |