diff options
Diffstat (limited to 'sys/dev/usb/ums.c')
-rw-r--r-- | sys/dev/usb/ums.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/sys/dev/usb/ums.c b/sys/dev/usb/ums.c index 946456632519..4d3578b7655c 100644 --- a/sys/dev/usb/ums.c +++ b/sys/dev/usb/ums.c @@ -363,7 +363,6 @@ static int ums_detach(device_t self) { struct ums_softc *sc = device_get_softc(self); - const char *devinfo = device_get_desc(self); if (sc->sc_enabled) { usbd_abort_pipe(sc->sc_intrpipe); @@ -372,10 +371,7 @@ ums_detach(device_t self) sc->sc_disconnected = 1; DPRINTF(("%s: disconnected\n", USBDEVNAME(self))); - if (devinfo) { - device_set_desc(self, NULL); - free((void *)devinfo, M_USB); - } + device_set_desc(self, NULL); free(sc->sc_loc_btn, M_USB); free(sc->sc_ibuf, M_USB); |