diff options
author | Timm Bäder <mail@baedert.org> | 2018-11-13 20:53:14 +0100 |
---|---|---|
committer | Timm Bäder <mail@baedert.org> | 2018-11-13 20:53:14 +0100 |
commit | 359d874ddbbc193fd0490fcfe18e96bc1b89619b (patch) | |
tree | 6609af8091a20bb4ed045b4c1e8b5a7aceae94f9 /gtk/gtkcheckbutton.c | |
parent | ade171a2ed1f868b13dd1f1cb221e6622b92e052 (diff) | |
download | gtk+-359d874ddbbc193fd0490fcfe18e96bc1b89619b.tar.gz |
Use g_clear_pointer to unparent widgets
Diffstat (limited to 'gtk/gtkcheckbutton.c')
-rw-r--r-- | gtk/gtkcheckbutton.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/gtk/gtkcheckbutton.c b/gtk/gtkcheckbutton.c index 09cecb126b..1be4a1e3a8 100644 --- a/gtk/gtkcheckbutton.c +++ b/gtk/gtkcheckbutton.c @@ -135,8 +135,7 @@ gtk_check_button_finalize (GObject *object) { GtkCheckButtonPrivate *priv = gtk_check_button_get_instance_private (GTK_CHECK_BUTTON (object)); - if (priv->indicator_widget) - gtk_widget_unparent (priv->indicator_widget); + g_clear_pointer (&priv->indicator_widget, gtk_widget_unparent); G_OBJECT_CLASS (gtk_check_button_parent_class)->finalize (object); } |