diff options
author | Jeffrey Stedfast <fejj@ximian.com> | 2001-03-15 08:51:09 +0800 |
---|---|---|
committer | Jeffrey Stedfast <fejj@src.gnome.org> | 2001-03-15 08:51:09 +0800 |
commit | 343844c13863d00b3210d11956056af8b1d367ce (patch) | |
tree | 4dcc10acea574a0c04faade1ce13a8e33e150782 /camel/providers/imap | |
parent | 1e9f8b5d127babb1837cf9572ff784a6173be244 (diff) | |
download | gsoc2013-evolution-343844c13863d00b3210d11956056af8b1d367ce.tar gsoc2013-evolution-343844c13863d00b3210d11956056af8b1d367ce.tar.gz gsoc2013-evolution-343844c13863d00b3210d11956056af8b1d367ce.tar.bz2 gsoc2013-evolution-343844c13863d00b3210d11956056af8b1d367ce.tar.lz gsoc2013-evolution-343844c13863d00b3210d11956056af8b1d367ce.tar.xz gsoc2013-evolution-343844c13863d00b3210d11956056af8b1d367ce.tar.zst gsoc2013-evolution-343844c13863d00b3210d11956056af8b1d367ce.zip |
Eek! So the service's URL isn't set until after this is initialized. This
2001-03-14 Jeffrey Stedfast <fejj@ximian.com>
* providers/imap/camel-imap-store.c (camel_imap_store_init): Eek!
So the service's URL isn't set until after this is
initialized. This means we can't check for SSL here.
(imap_connect): Set the SSL options here instead.
svn path=/trunk/; revision=8715
Diffstat (limited to 'camel/providers/imap')
-rw-r--r-- | camel/providers/imap/camel-imap-store.c | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/camel/providers/imap/camel-imap-store.c b/camel/providers/imap/camel-imap-store.c index db1c1f9c80..dd25bea6d9 100644 --- a/camel/providers/imap/camel-imap-store.c +++ b/camel/providers/imap/camel-imap-store.c @@ -144,17 +144,9 @@ camel_imap_store_init (gpointer object, gpointer klass) CamelRemoteStore *remote_store = CAMEL_REMOTE_STORE (object); CamelImapStore *imap_store = CAMEL_IMAP_STORE (object); CamelStore *store = CAMEL_STORE (object); - CamelURL *url; - url = CAMEL_SERVICE (store)->url; - - if (!g_strcasecmp (url->protocol, "imaps")) { - remote_store->default_port = 993; - remote_store->use_ssl = TRUE; - } else { - remote_store->default_port = 143; - remote_store->use_ssl = FALSE; - } + remote_store->default_port = 143; + remote_store->use_ssl = FALSE; imap_store->dir_sep = '\0'; imap_store->current_folder = NULL; @@ -401,12 +393,19 @@ imap_connect (CamelService *service, CamelException *ex) { CamelImapStore *store = CAMEL_IMAP_STORE (service); CamelSession *session = camel_service_get_session (service); + CamelServiceAuthType *authtype = NULL; char *result, *errbuf = NULL, *name; - CamelImapResponse *response; gboolean authenticated = FALSE; + CamelImapResponse *response; int len, i, flags; - CamelServiceAuthType *authtype = NULL; - + + if (!g_strcasecmp (service->url->protocol, "imaps")) { + CamelRemoteStore *rstore = CAMEL_REMOTE_STORE (service); + + rstore->default_port = 993; + rstore->use_ssl = TRUE; + } + if (connect_to_server (service, ex) == 0) return FALSE; |