[evolution-mapi] Bug #337479 - Evolution forgets password on any error



commit 4cadacc1eeeb77a6533cd271794a4045b99bcbf0
Author: Milan Crha <mcrha redhat com>
Date:   Mon May 10 17:42:24 2010 +0200

    Bug #337479 - Evolution forgets password on any error

 src/camel/camel-mapi-store.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/src/camel/camel-mapi-store.c b/src/camel/camel-mapi-store.c
index d82b856..d255a30 100644
--- a/src/camel/camel-mapi-store.c
+++ b/src/camel/camel-mapi-store.c
@@ -337,13 +337,14 @@ mapi_auth_loop (CamelService *service, CamelException *ex)
 
 	gchar *errbuf = NULL;
 	gboolean authenticated = FALSE;
+	guint32 prompt_flags = CAMEL_SESSION_PASSWORD_SECRET;
 
 	service->url->passwd = NULL;
 
 	while (!authenticated) {
 		if (errbuf) {
 			/* We need to un-cache the password before prompting again */
-			camel_session_forget_password (session, service, E_PASSWORD_COMPONENT, "password", ex);
+			prompt_flags |= CAMEL_SESSION_PASSWORD_REPROMPT;
 			g_free (service->url->passwd);
 			service->url->passwd = NULL;
 		}
@@ -361,7 +362,7 @@ mapi_auth_loop (CamelService *service, CamelException *ex)
 						  service->url->host);
 			service->url->passwd =
 				camel_session_get_password (session, service, E_PASSWORD_COMPONENT,
-							    prompt, "password", CAMEL_SESSION_PASSWORD_SECRET, ex);
+							    prompt, "password", prompt_flags, ex);
 			g_free (prompt);
 			g_free (errbuf);
 			errbuf = NULL;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]