mirror of
https://gitlab.uni-freiburg.de/opensourcevdi/spice
synced 2025-12-27 15:45:54 +00:00
server/red_channel: add red_channel_send_message_pending
This commit is contained in:
parent
7a650e9641
commit
88db43879b
@ -711,6 +711,11 @@ int red_channel_any_blocked(RedChannel *channel)
|
||||
return channel->send_data.blocked;
|
||||
}
|
||||
|
||||
int red_channel_send_message_pending(RedChannel *channel)
|
||||
{
|
||||
return channel->send_data.header->type != 0;
|
||||
}
|
||||
|
||||
/* accessors for RedChannel */
|
||||
SpiceMarshaller *red_channel_get_marshaller(RedChannel *channel)
|
||||
{
|
||||
|
||||
@ -257,6 +257,9 @@ int red_channel_all_blocked(RedChannel *channel);
|
||||
/* return TRUE if any of the connected clients to this channel are blocked */
|
||||
int red_channel_any_blocked(RedChannel *channel);
|
||||
|
||||
/* helper for channels that have complex logic that can possibly ready a send */
|
||||
int red_channel_send_message_pending(RedChannel *channel);
|
||||
|
||||
// TODO: unstaticed for display/cursor channels. they do some specific pushes not through
|
||||
// adding elements or on events. but not sure if this is actually required (only result
|
||||
// should be that they ""try"" a little harder, but if the event system is correct it
|
||||
|
||||
@ -7132,7 +7132,7 @@ static void red_lossy_send_qxl_drawable(RedWorker *worker, DisplayChannel *displ
|
||||
}
|
||||
|
||||
// a message is pending
|
||||
if (display_channel->common.base.send_data.header->type != 0) {
|
||||
if (red_channel_send_message_pending(&display_channel->common.base)) {
|
||||
display_begin_send_message(display_channel);
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user