diff options
Diffstat (limited to 'shell/e-corba-storage-registry.c')
-rw-r--r-- | shell/e-corba-storage-registry.c | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/shell/e-corba-storage-registry.c b/shell/e-corba-storage-registry.c index b7f69ef6fd..07db240d70 100644 --- a/shell/e-corba-storage-registry.c +++ b/shell/e-corba-storage-registry.c @@ -390,7 +390,7 @@ impl_StorageRegistry_getFolderByUri (PortableServer_Servant servant, /* GObject methods. */ static void -impl_finalize (GObject *object) +impl_dispose (GObject *object) { ECorbaStorageRegistry *corba_storage_registry; ECorbaStorageRegistryPrivate *priv; @@ -398,8 +398,23 @@ impl_finalize (GObject *object) corba_storage_registry = E_CORBA_STORAGE_REGISTRY (object); priv = corba_storage_registry->priv; - if (priv->storage_set != NULL) + if (priv->storage_set != NULL) { g_object_unref (priv->storage_set); + priv->storage_set = NULL; + } + + (* G_OBJECT_CLASS (parent_class)->dispose) (object); +} + +static void +impl_finalize (GObject *object) +{ + ECorbaStorageRegistry *corba_storage_registry; + ECorbaStorageRegistryPrivate *priv; + + corba_storage_registry = E_CORBA_STORAGE_REGISTRY (object); + priv = corba_storage_registry->priv; + g_free (priv); (* G_OBJECT_CLASS (parent_class)->finalize) (object); @@ -415,6 +430,7 @@ class_init (ECorbaStorageRegistryClass *klass) POA_GNOME_Evolution_StorageRegistry__epv *epv; object_class = G_OBJECT_CLASS (klass); + object_class->dispose = impl_dispose; object_class->finalize = impl_finalize; epv = & klass->epv; |