Use g_clear_object

The field we are freeing here might be NULL, as pointed
out by Cosimo.
This commit is contained in:
Matthias Clasen
2016-07-06 20:08:20 -04:00
parent ce28ecf7d4
commit 02b61966f3

View File

@@ -686,7 +686,7 @@ gtk_application_impl_dbus_finalize (GObject *object)
{
GtkApplicationImplDBus *dbus = (GtkApplicationImplDBus *) object;
g_object_unref (dbus->inhibit_proxy);
g_clear_object (&dbus->inhibit_proxy);
g_slist_free_full (dbus->inhibit_handles, inhibit_handle_free);
g_free (dbus->app_menu_path);
g_free (dbus->menubar_path);