On Thu, 2015-10-29 at 17:27 +0200, Dmitry Fleytman wrote: > From: Kirill Moizik <kmoizik@xxxxxxxxxx> > > During device disconnection, unwanted hotplug events may happen. > We need to ignore those therefore we track disconnection operations > in progress. > > See also comment to commit > "Do not process USB hotplug events while redirection is in progress" > that introduces corresponding filtering out logic. > > Signed-off-by: Kirill Moizik <kmoizik@xxxxxxxxxx> > Signed-off-by: Dmitry Fleytman <dfleytma@xxxxxxxxxx> > --- > src/usb-device-manager.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/src/usb-device-manager.c b/src/usb-device-manager.c > index 51b6c6d..d927ecd 100644 > --- a/src/usb-device-manager.c > +++ b/src/usb-device-manager.c > @@ -1728,6 +1728,8 @@ void _disconnect_device_async_cb(GObject *gobject, > } > #endif > > + _set_redirecting(self, FALSE); > + > g_simple_async_result_complete(result); > g_object_unref(result); > g_free(data); > @@ -1751,6 +1753,8 @@ void > spice_usb_device_manager_disconnect_device_async(SpiceUsbDeviceManager *sel > > SpiceUsbredirChannel *channel; > > + _set_redirecting(self, TRUE); > + > channel = spice_usb_device_manager_get_channel_for_dev(self, device); > nested = g_simple_async_result_new(G_OBJECT(self), callback, user_data, > > spice_usb_device_manager_disconnect_device_async); Acked-by: Jonathon Jongsma <jjongsma@xxxxxxxxxx> _______________________________________________ Spice-devel mailing list Spice-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/spice-devel