Trivial: Use g_clear_object more

It no longer has atomic overhead, so we can use it everywhere.
This commit is contained in:
Matthias Clasen 2014-08-09 10:13:55 +02:00
parent 9c7e31fc1c
commit 327b097725
2 changed files with 2 additions and 7 deletions

View File

@ -1398,11 +1398,7 @@ gtk_container_destroy (GtkWidget *widget)
if (priv->restyle_pending)
priv->restyle_pending = FALSE;
if (priv->focus_child)
{
g_object_unref (priv->focus_child);
priv->focus_child = NULL;
}
g_clear_object (&priv->focus_child);
/* do this before walking child widgets, to avoid
* removing children from focus chain one by one.

View File

@ -12140,8 +12140,7 @@ gtk_widget_finalize (GObject *object)
gtk_grab_remove (widget);
g_object_unref (priv->style);
priv->style = NULL;
g_clear_object (&priv->style);
g_free (priv->name);