summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorthompsa <thompsa@FreeBSD.org>2009-03-10 14:29:34 +0000
committerthompsa <thompsa@FreeBSD.org>2009-03-10 14:29:34 +0000
commit8e9f730d8e4866cfdbaa0ee82a06bad186dc5c6b (patch)
treecdefd99878ce747fb292ab38be86305c9ab247cd /lib
parent274c597d1c0c3db6aa964926e77f0ff4ea103d81 (diff)
downloadFreeBSD-src-8e9f730d8e4866cfdbaa0ee82a06bad186dc5c6b.zip
FreeBSD-src-8e9f730d8e4866cfdbaa0ee82a06bad186dc5c6b.tar.gz
Be compatible with LibUSB from sourceforge and close the handle after reset
Submitted by: Hans Petter Selasky
Diffstat (limited to 'lib')
-rw-r--r--lib/libusb/libusb20_compat01.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/libusb/libusb20_compat01.c b/lib/libusb/libusb20_compat01.c
index 5e1e8e1..aae819c 100644
--- a/lib/libusb/libusb20_compat01.c
+++ b/lib/libusb/libusb20_compat01.c
@@ -816,7 +816,11 @@ usb_reset(usb_dev_handle * dev)
if (err)
return (-1);
- return (0);
+ /*
+ * Be compatible with LibUSB from sourceforge and close the
+ * handle after reset!
+ */
+ return (usb_close(dev));
}
const char *
OpenPOWER on IntegriCloud