From 0d54c483525a76d4eedd41b9e5f59c241139bed3 Mon Sep 17 00:00:00 2001 From: Dan Winship Date: Tue, 9 Jan 2001 19:27:27 +0000 Subject: Kill off a long-hated Camel kludge: "empty" URLs and query_auth_types_generic. * camel-url.c: Remove "empty" from CamelURL. (camel_url_new): No longer set it. (camel_url_to_string): Treat "" as equivalent to NULL for authmech. (Unrelated change, but it simplifies some stuff with the new config dialog.) * camel-service.c (camel_service_new): Remove url->empty check: if the URL isn't valid, we don't create the service. (camel_service_query_auth_types): No longer need to switch between generic and connected variants. * providers/smtp/camel-smtp-transport.c (query_auth_types): * providers/pop3/camel-pop3-store.c (query_auth_types): * providers/nntp/camel-nntp-store.c (nntp_store_query_auth_types): * providers/imap/camel-imap-store.c (query_auth_types): * camel-remote-store.c (remote_query_auth_types): Remove generic version, rename connected version. svn path=/trunk/; revision=7327 --- camel/providers/imap/camel-imap-store.c | 22 ++++------------------ 1 file changed, 4 insertions(+), 18 deletions(-) (limited to 'camel/providers/imap') diff --git a/camel/providers/imap/camel-imap-store.c b/camel/providers/imap/camel-imap-store.c index 8774d783bd..7b3691efe6 100644 --- a/camel/providers/imap/camel-imap-store.c +++ b/camel/providers/imap/camel-imap-store.c @@ -58,8 +58,7 @@ static CamelRemoteStoreClass *remote_store_class = NULL; static gboolean imap_connect (CamelService *service, CamelException *ex); static gboolean imap_disconnect (CamelService *service, gboolean clean, CamelException *ex); -static GList *query_auth_types_generic (CamelService *service, CamelException *ex); -static GList *query_auth_types_connected (CamelService *service, CamelException *ex); +static GList *query_auth_types (CamelService *service, CamelException *ex); static CamelFolder *get_folder (CamelStore *store, const char *folder_name, guint32 flags, CamelException *ex); static char *get_folder_name (CamelStore *store, const char *folder_name, CamelException *ex); @@ -90,8 +89,7 @@ camel_imap_store_class_init (CamelImapStoreClass *camel_imap_store_class) (camel_remote_store_get_type ())); /* virtual method overload */ - camel_service_class->query_auth_types_generic = query_auth_types_generic; - camel_service_class->query_auth_types_connected = query_auth_types_connected; + camel_service_class->query_auth_types = query_auth_types; camel_service_class->connect = imap_connect; camel_service_class->disconnect = imap_disconnect; @@ -265,14 +263,14 @@ static CamelServiceAuthType kerberos_v4_authtype = { #endif static GList * -query_auth_types_connected (CamelService *service, CamelException *ex) +query_auth_types (CamelService *service, CamelException *ex) { GList *types; if (!connect_to_server (service, ex)) return NULL; - types = CAMEL_SERVICE_CLASS (remote_store_class)->query_auth_types_connected (service, ex); + types = CAMEL_SERVICE_CLASS (remote_store_class)->query_auth_types (service, ex); #ifdef HAVE_KRB4 if (CAMEL_IMAP_STORE (service)->capabilities & IMAP_CAPABILITY_AUTH_KERBEROS_V4) @@ -281,18 +279,6 @@ query_auth_types_connected (CamelService *service, CamelException *ex) return g_list_prepend (types, &password_authtype); } -static GList * -query_auth_types_generic (CamelService *service, CamelException *ex) -{ - GList *types; - - types = CAMEL_SERVICE_CLASS (remote_store_class)->query_auth_types_generic (service, ex); -#ifdef HAVE_KRB4 - types = g_list_prepend (types, &kerberos_v4_authtype); -#endif - return g_list_prepend (types, &password_authtype); -} - static gboolean imap_connect (CamelService *service, CamelException *ex) { -- cgit v1.2.3