[Spice-devel] [PATCH v4 7/7] UsbDeviceManager: fix usbdk standalone mode
Kirill Moizik
kirill at daynix.com
Thu Jun 18 05:46:20 PDT 2015
From: Kirill Moizik <kmoizik at redhat.com>
Only grey out the USB redirection widget if neither usbclerk nor usbdk
are available. Currently, spice_usb_device_manager_initable_init() will
return FALSE when UsbClerk is not
present even if we are trying to use UsbDk. This will cause the USB
redirection widget to be greyed out in the !usbclerk/usbdk case, which
is undesirable.
Signed-off-by: Kirill Moizik <kirillm at daynix.com>
---
src/usb-device-manager.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/src/usb-device-manager.c b/src/usb-device-manager.c
index 987cb20..5b8151f 100644
--- a/src/usb-device-manager.c
+++ b/src/usb-device-manager.c
@@ -259,10 +259,12 @@ static gboolean spice_usb_device_manager_initable_init(GInitable *initable,
#endif
#ifdef G_OS_WIN32
- priv->installer = spice_win_usb_driver_new(err);
- if (!priv->installer) {
- SPICE_DEBUG("failed to initialize winusb driver");
- return FALSE;
+ if (priv->use_usbclerk) {
+ priv->installer = spice_win_usb_driver_new(err);
+ if (!priv->installer) {
+ SPICE_DEBUG("failed to initialize winusb driver");
+ return FALSE;
+ }
}
#endif
--
2.1.0
More information about the Spice-devel
mailing list