diff options
author | Ettore Perazzoli <ettore@src.gnome.org> | 2001-10-12 13:23:47 +0800 |
---|---|---|
committer | Ettore Perazzoli <ettore@src.gnome.org> | 2001-10-12 13:23:47 +0800 |
commit | ac07e6a338f1dba0a4c5a5d044bb58b01e82a211 (patch) | |
tree | b96fd3eea4ace8b534f0bc3404a52117dd990db6 /shell/e-shell.c | |
parent | e7ea6195482eac08a8ea3239e7751592324791ef (diff) | |
download | gsoc2013-evolution-ac07e6a338f1dba0a4c5a5d044bb58b01e82a211.tar gsoc2013-evolution-ac07e6a338f1dba0a4c5a5d044bb58b01e82a211.tar.gz gsoc2013-evolution-ac07e6a338f1dba0a4c5a5d044bb58b01e82a211.tar.bz2 gsoc2013-evolution-ac07e6a338f1dba0a4c5a5d044bb58b01e82a211.tar.lz gsoc2013-evolution-ac07e6a338f1dba0a4c5a5d044bb58b01e82a211.tar.xz gsoc2013-evolution-ac07e6a338f1dba0a4c5a5d044bb58b01e82a211.tar.zst gsoc2013-evolution-ac07e6a338f1dba0a4c5a5d044bb58b01e82a211.zip |
[Hopefully really, finally fix #8615 and friends.]
* main.c (no_views_left_cb): Invoke `e_shell_disconnect_db()'
before unreffing the shell.
* e-shell.c (e_shell_disconnect_db): New.
(destroy): Call it instead of unreffing the db manually here.
svn path=/trunk/; revision=13616
Diffstat (limited to 'shell/e-shell.c')
-rw-r--r-- | shell/e-shell.c | 23 |
1 files changed, 19 insertions, 4 deletions
diff --git a/shell/e-shell.c b/shell/e-shell.c index 65a469bcf2..1f8628c2fe 100644 --- a/shell/e-shell.c +++ b/shell/e-shell.c @@ -766,10 +766,7 @@ destroy (GtkObject *object) shell = E_SHELL (object); priv = shell->priv; - if (shell->priv->db != CORBA_OBJECT_NIL) { - bonobo_object_release_unref (shell->priv->db, NULL); - shell->priv->db = CORBA_OBJECT_NIL; - } + e_shell_disconnect_db (shell); if (priv->iid != NULL) oaf_active_server_unregister (priv->iid, bonobo_object_corba_objref (BONOBO_OBJECT (shell))); @@ -1678,6 +1675,8 @@ e_shell_get_user_creatable_items_handler (EShell *shell) } +/* FIXME: These are ugly hacks, they really should not be needed. */ + void e_shell_unregister_all (EShell *shell) { @@ -1693,6 +1692,22 @@ e_shell_unregister_all (EShell *shell) priv->component_registry = NULL; } +void +e_shell_disconnect_db (EShell *shell) +{ + EShellPrivate *priv; + + g_return_if_fail (E_IS_SHELL (shell)); + + priv = shell->priv; + + if (priv->db == CORBA_OBJECT_NIL) + return; + + bonobo_object_release_unref (priv->db, NULL); + priv->db = CORBA_OBJECT_NIL; +} + const char * e_shell_construct_result_to_string (EShellConstructResult result) |