[Spice-devel] [PATCH spice-gtk 2/2] usb: stop processing usb events on error
Marc-André Lureau
marcandre.lureau at redhat.com
Fri Nov 7 11:41:59 PST 2014
If libusb returned an error in the event loop, stop further event
handling. This avoid spinning in an error loop in error cases.
---
gtk/usb-device-manager.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/gtk/usb-device-manager.c b/gtk/usb-device-manager.c
index 5013b6c..61daa17 100644
--- a/gtk/usb-device-manager.c
+++ b/gtk/usb-device-manager.c
@@ -1150,6 +1150,7 @@ static gpointer spice_usb_device_manager_usb_ev_thread(gpointer user_data)
if (rc && rc != LIBUSB_ERROR_INTERRUPTED) {
const char *desc = spice_usbutil_libusb_strerror(rc);
g_warning("Error handling USB events: %s [%i]", desc, rc);
+ break;
}
}
--
1.9.3
More information about the Spice-devel
mailing list