Re: [PATCH spice-gtk 3/9] channel: reset connection state on error

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jan 13, 2015 at 05:38:22PM +0100, Marc-André Lureau wrote:
> Fix regression introduced in 6b475802, to permit reconnection on error,
> the channel state must be < STATE_CONNECTING. Since the error is
> reported after coroutine exits and channel is reset, the state can be
> modified before throwing the error now.


ACK.

> ---
>  gtk/spice-channel.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/gtk/spice-channel.c b/gtk/spice-channel.c
> index 7c7cbe1..eb97e78 100644
> --- a/gtk/spice-channel.c
> +++ b/gtk/spice-channel.c
> @@ -2242,6 +2242,7 @@ static gboolean spice_channel_delayed_unref(gpointer data)
>      g_return_val_if_fail(c->coroutine.coroutine.exited == TRUE, FALSE);
>  
>      if (c->event != SPICE_CHANNEL_NONE) {
> +        c->state = SPICE_CHANNEL_STATE_UNCONNECTED;
>          g_coroutine_signal_emit(channel, signals[SPICE_CHANNEL_EVENT], 0, c->event);
>          c->event = SPICE_CHANNEL_NONE;
>          g_clear_error(&c->error);
> -- 
> 2.1.0
> 
> _______________________________________________
> Spice-devel mailing list
> Spice-devel@xxxxxxxxxxxxxxxxxxxxx
> http://lists.freedesktop.org/mailman/listinfo/spice-devel

Attachment: pgpp5UrBTbPnJ.pgp
Description: PGP signature

_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/spice-devel

[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]