aboutsummaryrefslogtreecommitdiffstats
path: root/addressbook/gui/component/select-names/e-simple-card-bonobo.c
diff options
context:
space:
mode:
Diffstat (limited to 'addressbook/gui/component/select-names/e-simple-card-bonobo.c')
-rw-r--r--addressbook/gui/component/select-names/e-simple-card-bonobo.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/addressbook/gui/component/select-names/e-simple-card-bonobo.c b/addressbook/gui/component/select-names/e-simple-card-bonobo.c
index f61c6d1866..0577daa648 100644
--- a/addressbook/gui/component/select-names/e-simple-card-bonobo.c
+++ b/addressbook/gui/component/select-names/e-simple-card-bonobo.c
@@ -140,13 +140,17 @@ impl_dispose (GObject *object)
simple_card = E_SIMPLE_CARD_BONOBO (object);
priv = simple_card->priv;
- if (priv->card_simple) {
- g_object_unref (priv->card_simple);
- }
+ if (priv) {
+ if (priv->card_simple) {
+ g_object_unref (priv->card_simple);
+ }
- g_free (priv);
+ g_free (priv);
+ simple_card->priv = NULL;
+ }
- simple_card->priv = NULL;
+ if (G_OBJECT_CLASS(parent_class)->dispose)
+ G_OBJECT_CLASS(parent_class)->dispose(object);
}