[gnome-control-center] [about-me] Don't hang when new and old password only differ in case
- From: Milan Bouchet-Valat <milanbv src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-control-center] [about-me] Don't hang when new and old password only differ in case
- Date: Sun, 4 Apr 2010 15:11:19 +0000 (UTC)
commit 8a31bf892c69cbb04b82c06b7f23154cbc7b34a5
Author: Milan Bouchet-Valat <nalimilan club fr>
Date: Tue Mar 23 20:43:16 2010 +0100
[about-me] Don't hang when new and old password only differ in case
'passwd' returns an error when the new and the old passwords only differ in case. If we don't handle this (unlikely) case, users-admin hangs. Assimilate this error to "passwords are too similar".
capplets/about-me/gnome-about-me-password.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/capplets/about-me/gnome-about-me-password.c b/capplets/about-me/gnome-about-me-password.c
index 7fbe8f5..27e75b3 100644
--- a/capplets/about-me/gnome-about-me-password.c
+++ b/capplets/about-me/gnome-about-me-password.c
@@ -506,6 +506,7 @@ io_watch_stdout (GIOChannel *source, GIOCondition condition, PasswordDialog *pdi
"dictionary",
"simple",
"similar",
+ "case",
"wrapped",
"recovered",
"unchanged",
@@ -540,6 +541,7 @@ io_watch_stdout (GIOChannel *source, GIOCondition condition, PasswordDialog *pdi
g_strrstr (str->str, "dictionary") != NULL) {
msg = g_strdup (_("The password is too simple."));
} else if (g_strrstr (str->str, "similar") != NULL ||
+ g_strrstr (str->str, "case") != NULL ||
g_strrstr (str->str, "wrapped") != NULL) {
msg = g_strdup (_("The old and new passwords are too similar."));
} else if (g_strrstr (str->str, "1 numeric or special") != NULL) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]