From 5cefd27bef67d8408c403edce24d4ab3bbc8fc67 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Fri, 30 Mar 2012 16:05:20 -0500 Subject: If we're going to unref we should set to NULL to catch potential errors --- libdbusmenu-glib/client.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'libdbusmenu-glib') diff --git a/libdbusmenu-glib/client.c b/libdbusmenu-glib/client.c index 2d07f0c..98329a1 100644 --- a/libdbusmenu-glib/client.c +++ b/libdbusmenu-glib/client.c @@ -1116,6 +1116,7 @@ menuproxy_build_cb (GObject * object, GAsyncResult * res, gpointer user_data) g_object_notify(G_OBJECT(user_data), DBUSMENU_CLIENT_PROP_TEXT_DIRECTION); g_variant_unref(textdir); + textdir = NULL; } /* Check the status if available */ @@ -1131,6 +1132,7 @@ menuproxy_build_cb (GObject * object, GAsyncResult * res, gpointer user_data) g_object_notify(G_OBJECT(user_data), DBUSMENU_CLIENT_PROP_STATUS); g_variant_unref(status); + status = NULL; } /* Get the icon theme directories if available */ @@ -1145,6 +1147,7 @@ menuproxy_build_cb (GObject * object, GAsyncResult * res, gpointer user_data) g_signal_emit(G_OBJECT(client), signals[ICON_THEME_DIRS], 0, priv->icon_dirs, TRUE); g_variant_unref(icon_dirs); + icon_dirs = NULL; } /* Get the icon theme directories if available */ -- cgit v1.2.3