[Spice-devel] [PATCHv2 01/10] channel: delay event report to after coroutine exit
Christophe Fergeau
cfergeau at redhat.com
Tue Jan 27 08:11:30 PST 2015
On Tue, Jan 27, 2015 at 02:53:14PM +0100, Marc-André Lureau wrote:
> @@ -2157,9 +2156,8 @@ static gboolean spice_channel_iterate(SpiceChannel *channel)
> if (ret & (G_IO_ERR|G_IO_HUP)) {
> CHANNEL_DEBUG(channel, "channel got error");
> if (c->state > SPICE_CHANNEL_STATE_CONNECTING) {
> - g_coroutine_signal_emit(channel, signals[SPICE_CHANNEL_EVENT], 0,
> - c->state == SPICE_CHANNEL_STATE_READY ?
> - SPICE_CHANNEL_ERROR_IO : SPICE_CHANNEL_ERROR_LINK);
> + c->event = c->state == SPICE_CHANNEL_STATE_READY ?
> + SPICE_CHANNEL_ERROR_IO : SPICE_CHANNEL_ERROR_LINK;
if (c->state == SPICE_CHANNEL_STATE_READY)
c->event = SPICE_CHANNEL_ERROR_IO;
else
c->event = SPICE_CHANNEL_ERROR_LINK;
would be much more readable imo.
ACK apart from this.
Christophe
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/spice-devel/attachments/20150127/91207520/attachment-0001.sig>
More information about the Spice-devel
mailing list