[Spice-devel] [PATCH spice-gtk] spice-channel: Allow calling spice_msg_out_send from any context
Hans de Goede
hdegoede at redhat.com
Tue Jan 17 04:58:52 PST 2012
Hi,
On 01/17/2012 01:50 PM, Alon Levy wrote:
>> @@ -664,17 +681,23 @@ void spice_msg_out_send(SpiceMsgOut *out)
>> g_return_if_fail(out->channel != NULL);
>>
>> g_static_mutex_lock(&out->channel->priv->xmit_queue_lock);
>> - if (!out->channel->priv->xmit_queue_blocked)
>
> Just one thing I don't understand, not related to the current patch (was
> this way before) - we drop everything on the floor if
> xmit_queue_blocked, which is only set between channel_reset and
> channel_connect. Why don't we log this error? (no, I'm not saying we
> should assert on this..)
xmit_queue_blocked is there to stop the usb event thread from queuing
new usbredir packets (like hey this and this usb transfer failed with
-ENODEV) after a device (and thus also a usbredir channel)
disconnect.
So the if actually is expected to trigger in some normal cases, hence no
error log.
Regards,
Hans
More information about the Spice-devel
mailing list