[evolution-mapi] Reprompt password if given wrong
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-mapi] Reprompt password if given wrong
- Date: Wed, 9 Mar 2011 13:02:06 +0000 (UTC)
commit 6a7ff6e388fd426c50c357475272549cd0819804
Author: Milan Crha <mcrha redhat com>
Date: Wed Mar 9 14:01:50 2011 +0100
Reprompt password if given wrong
.../exchange-mapi-account-listener.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/src/account-setup-eplugin/exchange-mapi-account-listener.c b/src/account-setup-eplugin/exchange-mapi-account-listener.c
index 2572f4a..418eb97 100644
--- a/src/account-setup-eplugin/exchange-mapi-account-listener.c
+++ b/src/account-setup-eplugin/exchange-mapi-account-listener.c
@@ -1110,14 +1110,15 @@ create_profile_entry (CamelURL *url, EAccount *account)
gchar *password = NULL, *key = NULL;
key = camel_url_to_string (url, CAMEL_URL_HIDE_PASSWORD | CAMEL_URL_HIDE_PARAMS);
- password = e_passwords_get_password (EXCHANGE_MAPI_PASSWORD_COMPONENT, key);
+ if (!attempts)
+ password = e_passwords_get_password (EXCHANGE_MAPI_PASSWORD_COMPONENT, key);
if (!password) {
gboolean remember = account && e_account_get_bool (account, E_ACCOUNT_SOURCE_SAVE_PASSWD);
gchar *title;
title = g_strdup_printf (_("Enter Password for %s %s"), url->user, url->host);
password = e_passwords_ask_password (title, EXCHANGE_MAPI_PASSWORD_COMPONENT, key, title,
- E_PASSWORDS_REMEMBER_FOREVER|E_PASSWORDS_SECRET,
+ E_PASSWORDS_REMEMBER_FOREVER | E_PASSWORDS_SECRET | (attempts ? E_PASSWORDS_REPROMPT : 0),
&remember, NULL);
g_free (title);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]