<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div class="">hi, everyone.</div><div class="">        when I unplug a USB Storage from client machine,  the guest desktop </div><div class="">will unresponsive at thus case:</div><div class=""><br class=""></div><div class="">1. the USB Storage device with 16G or 32G has redir to the guest desktop, and coping some big file.</div><div class="">then unplug the USB Storage device from the client machine.</div><div class=""><br class=""></div><div class="">2. when the USB Storage device is being <span style="color: rgb(61, 61, 61); font-family: Arial, sans-serif; background-color: rgb(255, 255, 255);" class="">identified in the guest os, then unplug from the client machine.</span></div><div class=""><span style="color: rgb(61, 61, 61); font-family: Arial, sans-serif; background-color: rgb(255, 255, 255);" class=""><br class=""></span></div><div class=""><span style="color: rgb(61, 61, 61); font-family: Arial, sans-serif; background-color: rgb(255, 255, 255);" class="">3. when the guest is check on the auto_redir, then plugin and unplug the USB Storage Device frequently.</span></div><div class=""><span style="color: rgb(61, 61, 61); font-family: Arial, sans-serif; background-color: rgb(255, 255, 255);" class=""><br class=""></span></div><div class=""><span style="color: rgb(61, 61, 61); font-family: Arial, sans-serif; background-color: rgb(255, 255, 255);" class=""><br class=""></span></div><div class=""><span style="background-color: rgb(255, 255, 255);" class=""><font color="#3d3d3d" face="Arial, sans-serif" class="">I don’t know whether the patch code is c</font></span><span style="color: rgb(61, 61, 61); font-family: Arial, sans-serif; background-color: rgb(255, 255, 255);" class="">orrect</span><span style="background-color: rgb(255, 255, 255);" class=""><font color="#3d3d3d" face="Arial, sans-serif" class="">, but the desktop not unresponsive at upon cases.</font></span></div><div class=""><span style="background-color: rgb(255, 255, 255);" class=""><font color="#3d3d3d" face="Arial, sans-serif" class=""><br class=""></font></span></div><div class=""><font color="#3d3d3d" face="Arial, sans-serif" class=""><span style="background-color: rgb(255, 255, 255);" class="">I debugged the code, when into </span></font>coroutine_yield and the device is unplugged, sometimes, this usbreidr-channel</div><div class="">will not be unlocked.</div><div class=""><br class=""></div><br class="">
<div class="">diff --git a/src/channel-usbredir.c b/src/channel-usbredir.c</div><div class="">index fef62ce..1f791bc 100644</div><div class="">--- a/src/channel-usbredir.c</div><div class="">+++ b/src/channel-usbredir.c</div><div class="">@@ -927,15 +927,16 @@ static void usbredir_handle_msg(SpiceChannel *c, SpiceMsgIn *in)</div><div class="">         err_data.caller = coroutine_self();</div><div class="">         err_data.spice_device = g_boxed_copy(spice_usb_device_get_type(), spice_device);</div><div class="">         err_data.error = err;</div><div class="">+        spice_usbredir_channel_unlock(channel);</div><div class="">         g_idle_add(device_error, &err_data);</div><div class="">         coroutine_yield(NULL);</div><div class=""> </div><div class="">         g_boxed_free(spice_usb_device_get_type(), err_data.spice_device);</div><div class=""> </div><div class="">         g_error_free(err);</div><div class="">+    } else {</div><div class="">+        spice_usbredir_channel_unlock(channel);</div><div class="">     }</div><div class="">-</div><div class="">-    spice_usbredir_channel_unlock(channel);</div><div class=""> }</div><div class=""> </div><div class=""> #endif /* USE_USBREDIR */</div><div class=""><br class=""></div></body></html>