camel_object_unref (CAMEL_OBJECT(priv->session));
priv->session = NULL;
}
+
+ camel_shutdown ();
G_OBJECT_CLASS(parent_class)->finalize (obj);
}
TnyAccount *account,
TnyAlertType type,
gboolean question,
- const GError *error)
+ GError *error)
{
ModestTransportStoreProtocol proto =
MODEST_PROTOCOL_TRANSPORT_STORE_UNKNOWN;
klass = (TnyAccountStoreIface *)g;
- klass->get_accounts_func =
+ klass->get_accounts =
modest_tny_account_store_get_accounts;
- klass->get_cache_dir_func =
+ klass->get_cache_dir =
modest_tny_account_store_get_cache_dir;
- klass->get_device_func =
+ klass->get_device =
modest_tny_account_store_get_device;
- klass->alert_func =
+ klass->alert =
modest_tny_account_store_alert;
- klass->find_account_func =
+ klass->find_account =
modest_tny_account_store_find_account_by_url;
}
g_object_unref (tmp_account);
tny_iterator_next (iter);
}
+ g_object_unref (iter);
if (!found) {
g_printerr ("modest: %s: could not get tny %s account for %s\n." \
}
TnyAccount*
-modest_tny_account_store_get_smtp_specific_transport_account_for_open_connection (ModestTnyAccountStore *self,
- const gchar *account_name)
+modest_tny_account_store_get_smtp_specific_transport_account_for_open_connection (
+ ModestTnyAccountStore *self, const gchar *account_name)
{
TnyDevice *device;
/* Get the current connection: */
device = modest_runtime_get_device ();
-
+
+ if (!device) {
+ g_warning ("%s: could not get device", __FUNCTION__);
+ return NULL;
+ }
+
if (!tny_device_is_online (device))
return NULL;
g_object_unref (folder);
tny_iterator_next (folders_iter);
}
+ g_object_unref (folders_iter);
g_object_unref (folders);
g_object_unref (account);