|
|
850466 |
From 3a88b01e459d38bbeed05d3ba8f4a1f07f34e0b8 Mon Sep 17 00:00:00 2001
|
|
|
850466 |
From: Trent Lloyd <trent@lloyd.id.au>
|
|
|
850466 |
Date: Thu, 16 Jan 2014 12:58:24 +0800
|
|
|
850466 |
Subject: [PATCH] avahi-ui: Cannot use g_object_unref to free GdkCursor in GTK2
|
|
|
850466 |
|
|
|
850466 |
GdkCursor does not use GObject in GTK2
|
|
|
850466 |
---
|
|
|
850466 |
avahi-ui/avahi-ui.c | 6 +++++-
|
|
|
850466 |
1 file changed, 5 insertions(+), 1 deletion(-)
|
|
|
850466 |
|
|
|
850466 |
diff --git a/avahi-ui/avahi-ui.c b/avahi-ui/avahi-ui.c
|
|
|
850466 |
index ff33a89..8f90b27 100644
|
|
|
850466 |
--- a/avahi-ui/avahi-ui.c
|
|
|
850466 |
+++ b/avahi-ui/avahi-ui.c
|
|
|
850466 |
@@ -890,7 +890,11 @@ static void response_callback(GtkDialog *dialog, gint response, gpointer user_da
|
|
|
850466 |
gtk_widget_set_sensitive(GTK_WIDGET(dialog), FALSE);
|
|
|
850466 |
cursor = gdk_cursor_new(GDK_WATCH);
|
|
|
850466 |
gdk_window_set_cursor(gtk_widget_get_window(GTK_WIDGET(dialog)), cursor);
|
|
|
850466 |
- g_object_unref(G_OBJECT(cursor));
|
|
|
850466 |
+#if GTK_CHECK_VERSION(3,0,0)
|
|
|
850466 |
+ g_object_unref(cursor);
|
|
|
850466 |
+#else
|
|
|
850466 |
+ gdk_cursor_unref(cursor);
|
|
|
850466 |
+#endif
|
|
|
850466 |
|
|
|
850466 |
if (!(d->priv->resolver = avahi_service_resolver_new(
|
|
|
850466 |
d->priv->client, interface, protocol, name, type, d->priv->domain,
|
|
|
850466 |
--
|
|
|
850466 |
2.7.4
|
|
|
850466 |
|