diff options
Diffstat (limited to 'sys/dev/usb/if_rum.c')
-rw-r--r-- | sys/dev/usb/if_rum.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sys/dev/usb/if_rum.c b/sys/dev/usb/if_rum.c index ddffda0332d..b2cce3b8adb 100644 --- a/sys/dev/usb/if_rum.c +++ b/sys/dev/usb/if_rum.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_rum.c,v 1.91 2010/10/23 15:42:09 jakemsr Exp $ */ +/* $OpenBSD: if_rum.c,v 1.92 2010/10/23 16:14:07 jakemsr Exp $ */ /*- * Copyright (c) 2005-2007 Damien Bergamini <damien.bergamini@free.fr> @@ -464,8 +464,10 @@ rum_detach(struct device *self, int flags) if_detach(ifp); usb_rem_task(sc->sc_udev, &sc->sc_task); - timeout_del(&sc->scan_to); - timeout_del(&sc->amrr_to); + if (timeout_initialized(&sc->scan_to)) + timeout_del(&sc->scan_to); + if (timeout_initialized(&sc->amrr_to)) + timeout_del(&sc->amrr_to); if (sc->amrr_xfer != NULL) { usbd_free_xfer(sc->amrr_xfer); |