* all:
[modest] / src / modest-runtime.c
index 08eb861..c4bbdc8 100644 (file)
@@ -183,14 +183,13 @@ modest_runtime_init_ui (gint argc, gchar** argv)
 gboolean
 modest_runtime_uninit (void)
 {
-       if (!_singletons) {
-               g_printerr ("modest: modest_runtime is not initialized\n");
-               return FALSE;
+       if (_singletons) {
+               g_object_unref (G_OBJECT(_singletons));
+               _singletons = NULL;
        }
+       if (G_IS_OBJECT(_singletons)) 
+               g_warning ("BUG: _singletons is still alive\n");
        
-       g_object_unref (G_OBJECT(_singletons));
-       _singletons = NULL;
-
        return TRUE;
 }
 
@@ -234,6 +233,7 @@ modest_runtime_get_mail_operation_queue (void)
 }
 
 
+
 ModestTnySendQueue*
 modest_runtime_get_send_queue  (TnyTransportAccount *account)
 {
@@ -446,7 +446,7 @@ init_default_account_maybe  (ModestAccountMgr *acc_mgr)
        gchar *default_account;
        gboolean retval = TRUE;
        
-       all_accounts = modest_account_mgr_account_names (acc_mgr, NULL);
+       all_accounts = modest_account_mgr_account_names (acc_mgr);
        if (all_accounts) { /* if there are any accounts, there should be a default one */
                default_account = 
                        modest_account_mgr_get_default_account (acc_mgr);