Re: [PATCH spice-gtk v3 1/2] desktop: Do not try org.gnome.SessionManager on Windows or Mac

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

 



> 
> From: Marc-André Lureau <marcandre.lureau@xxxxxxxxxx>
> 
> DBus support is available on those systems, yet it doesn't make sense
> to attempt to connect to GNOME session manager.
> 
> Mark gnome_integration_init() as unused. The following patch is
> compiling out the GNOME support instead. It is not squashed here,
> because it makes reviewing much harder.
> 
> Fixes:
> https://gitlab.freedesktop.org/spice/spice-gtk/issues/81
> 
> Signed-off-by: Marc-André Lureau <marcandre.lureau@xxxxxxxxxx>
> ---
>  src/desktop-integration.c | 9 +++++++--
>  1 file changed, 7 insertions(+), 2 deletions(-)
> 
> diff --git a/src/desktop-integration.c b/src/desktop-integration.c
> index 7c433bb..2b936f4 100644
> --- a/src/desktop-integration.c
> +++ b/src/desktop-integration.c
> @@ -53,6 +53,7 @@ static void handle_dbus_call_error(const char *call, GError
> **_error)
>      g_clear_error(_error);
>  }
>  
> +G_GNUC_UNUSED
>  static gboolean gnome_integration_init(SpiceDesktopIntegration *self)
>  {
>      G_GNUC_UNUSED SpiceDesktopIntegrationPrivate *priv = self->priv;
> @@ -160,8 +161,12 @@ static void
> spice_desktop_integration_init(SpiceDesktopIntegration *self)
>      priv = spice_desktop_integration_get_instance_private(self);
>      self->priv = priv;
>  
> -    if (!gnome_integration_init(self))
> -       g_warning("Warning no automount-inhibiting implementation
> available");
> +#if defined(G_OS_UNIX) && !__APPLE__
> +    if (gnome_integration_init(self))
> +        return;

style: missing brackets

> +#endif
> +
> +    g_warning("Warning no automount-inhibiting implementation available");
>  }
>  
>  static void spice_desktop_integration_dispose(GObject *gobject)

Acked with the style fixed.

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




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