diff options
author | Milan Crha <mcrha@redhat.com> | 2011-11-01 18:03:15 +0800 |
---|---|---|
committer | Milan Crha <mcrha@redhat.com> | 2011-11-01 18:03:15 +0800 |
commit | ea8d9ff8f57c331b13afbea59160540f21fdca28 (patch) | |
tree | 2428d42f01d173ba388d78282d05cb388a595ca3 | |
parent | 8cd9a0850471f474533e4cbe02dc2302e1e441fd (diff) | |
download | gsoc2013-evolution-ea8d9ff8f57c331b13afbea59160540f21fdca28.tar.gz gsoc2013-evolution-ea8d9ff8f57c331b13afbea59160540f21fdca28.tar.zst gsoc2013-evolution-ea8d9ff8f57c331b13afbea59160540f21fdca28.zip |
Bug #627952 - 'Local delivery' mbox's aren't read properly
-rw-r--r-- | mail/em-account-editor.c | 31 |
1 files changed, 26 insertions, 5 deletions
diff --git a/mail/em-account-editor.c b/mail/em-account-editor.c index 86228b7182..87ff312fe1 100644 --- a/mail/em-account-editor.c +++ b/mail/em-account-editor.c @@ -2162,12 +2162,10 @@ emae_setup_service (EMAccountEditor *emae, EAccount *account; struct _service_info *info = &emae_service_info[service->type]; CamelURL *url = emae_account_url (emae, info->account_uri_key); - const gchar *uri; account = em_account_editor_get_modified_account (emae); - uri = e_account_get_string (account, info->account_uri_key); - service->provider = uri ? camel_provider_get (uri, NULL) : NULL; + service->provider = url && url->protocol ? camel_provider_get (url->protocol, NULL) : NULL; /* Extract all widgets we need from the builder file. */ @@ -4072,9 +4070,21 @@ emae_commit (EConfig *ec, url = camel_url_new (modified_account->source->url, NULL); if (url != NULL) { - if (emae->priv->source.settings != NULL) + if (emae->priv->source.settings != NULL) { + gchar *host = g_strdup (url->host); + gchar *path = g_strdup (url->path); + gint port = url->port; + camel_settings_save_to_url ( emae->priv->source.settings, url); + + camel_url_set_host (url, host); + camel_url_set_path (url, path); + camel_url_set_port (url, port); + + g_free (host); + g_free (path); + } g_free (modified_account->source->url); modified_account->source->url = camel_url_to_string (url, 0); camel_url_free (url); @@ -4082,9 +4092,20 @@ emae_commit (EConfig *ec, url = camel_url_new (modified_account->transport->url, NULL); if (url != NULL) { - if (emae->priv->transport.settings != NULL) + if (emae->priv->transport.settings != NULL) { + gchar *host = g_strdup (url->host); + gchar *path = g_strdup (url->path); + gint port = url->port; + camel_settings_save_to_url ( emae->priv->transport.settings, url); + camel_url_set_host (url, host); + camel_url_set_path (url, path); + camel_url_set_port (url, port); + + g_free (host); + g_free (path); + } g_free (modified_account->transport->url); modified_account->transport->url = camel_url_to_string (url, 0); camel_url_free (url); |