Re: [PATCH 06/16] char-device: notify when device instance is changed

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

 



> 
> Since the device instance ("sin") is a gobject property, we should make
> sure to notify when it changes, particularly since we do some
> initialization in response to the "notify::sin" signal.
> ---
>  server/char-device.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/server/char-device.c b/server/char-device.c
> index 3f20831..90eb3d4 100644
> --- a/server/char-device.c
> +++ b/server/char-device.c
> @@ -706,6 +706,7 @@ void red_char_device_reset_dev_instance(RedCharDevice
> *state,
>      spice_debug("sin %p dev_state %p", sin, state);
>      state->priv->sin = sin;
>      sin->st = state;
> +    g_object_notify(G_OBJECT(state), "sin");
>  }
>  
>  void *red_char_device_opaque_get(RedCharDevice *dev)
> @@ -865,6 +866,7 @@ void red_char_device_reset(RedCharDevice *dev)
>          red_char_device_client_send_queue_free(dev, dev_client);
>      }
>      dev->priv->sin = NULL;
> +    g_object_notify(G_OBJECT(dev), "sin");
>  }
>  
>  void red_char_device_wakeup(RedCharDevice *dev)

Acked-by: Frediano Ziglio <fziglio@xxxxxxxxxx>

Frediano
_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
https://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]