Re: [spice-gtk Win32 v2 PATCH 3/5] Windows mingw: usb: add win-usb-dev.[ch]: implement GUdevDevice & GUdevClient

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I am working on removal of all libusb dependency in win-usb-dev, which cleanups this mess.

Hans de Goede wrote:
diff --git a/gtk/win-usb-dev.c b/gtk/win-usb-dev.c
new file mode 100644
index 0000000..7503c41
--- /dev/null
+++ b/gtk/win-usb-dev.c

<snip>

+    rc = libusb_init(NULL);
+    g_return_val_if_fail(rc>= 0, FALSE);

Ugh using a global libusb context is BAD, remember spice-gtk is a library, so in the long run it could get linked into a program which is also using libusb in some other way.

This is acceptable for now, but it really should be high on the TODO list of things
to fix. OTOH we might get hotplug support in libusbx first :)

Regards,

Hans
_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/spice-devel

_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/spice-devel


[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]