* See http://libusbx.1081486.n5.nabble.com/Libusbx-devel-stress-program-crashes-in-libusb-exit-NULL-tp474p477.html
/* default context should be initialized before calling usbi_dbg */
if (!usbi_default_context) {
usbi_default_context = ctx;
+ default_context_refcnt++;
usbi_dbg("created default context");
}
if (context) {
*context = ctx;
- } else if (!usbi_default_context) {
- usbi_dbg("created default context");
- usbi_default_context = ctx;
- default_context_refcnt++;
}
usbi_mutex_static_unlock(&default_context_lock);
-#define LIBUSB_NANO 10589
+#define LIBUSB_NANO 10590