[nautilus] Don't unref the DBus proxy if it's NULL



commit f985fe76918ef299e3b580fef8922045c9a4cfed
Author: Cosimo Cecchi <cosimoc gnome org>
Date:   Tue Aug 3 01:47:57 2010 +0200

    Don't unref the DBus proxy if it's NULL

 libnautilus-private/nautilus-mime-actions.c |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/libnautilus-private/nautilus-mime-actions.c b/libnautilus-private/nautilus-mime-actions.c
index 43489bf..b2d4c2e 100644
--- a/libnautilus-private/nautilus-mime-actions.c
+++ b/libnautilus-private/nautilus-mime-actions.c
@@ -1153,11 +1153,15 @@ activate_parameters_install_free (ActivateParametersInstall *parameters_install)
 	if (parameters_install->parent_window) {
 		g_object_remove_weak_pointer (G_OBJECT (parameters_install->parent_window), (gpointer *)&parameters_install->parent_window);
 	}
+
+	if (parameters_install->proxy != NULL) {
+	        g_object_unref (parameters_install->proxy);
+	}
+
 	nautilus_file_unref (parameters_install->file);
 	nautilus_file_list_free (parameters_install->files);
 	g_free (parameters_install->activation_directory);
 	g_free (parameters_install->uri);
-        g_object_unref (parameters_install->proxy);
 	g_free (parameters_install);
 }
 



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