From 2e1605c30eab52782463a68da28e2a8a90180bf5 Mon Sep 17 00:00:00 2001 From: Sankar P Date: Tue, 11 Dec 2007 05:32:58 +0000 Subject: ** Fix for bug #501969 Passwords should not be forgotten for all errors 2007-12-11 Sankar P ** Fix for bug #501969 * Passwords should not be forgotten for all errors svn path=/trunk/; revision=34686 --- calendar/gui/gnome-cal.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'calendar/gui') diff --git a/calendar/gui/gnome-cal.c b/calendar/gui/gnome-cal.c index 98dc0c566d..e396b879ff 100644 --- a/calendar/gui/gnome-cal.c +++ b/calendar/gui/gnome-cal.c @@ -43,6 +43,8 @@ #include #include #include +#include + #include "e-util/e-config-listener.h" #include "shell/e-user-creatable-items-handler.h" #include @@ -2651,6 +2653,17 @@ client_cal_opened_cb (ECal *ecal, ECalendarStatus status, GnomeCalendar *gcal) e_error_run (NULL, "calendar:server-version", NULL); status = E_CALENDAR_STATUS_OK; break; + case E_CALENDAR_STATUS_AUTHENTICATION_FAILED: + { + const gchar *auth_domain = e_source_get_property (source, "auth-domain"); + const gchar *component_name; + + component_name = auth_domain ? auth_domain : "Calendar"; + + /* Warn the user password is wrong */ + e_passwords_forget_password (component_name, e_cal_get_uri(ecal)); + return; + } case E_CALENDAR_STATUS_REPOSITORY_OFFLINE: if (source_type == E_CAL_SOURCE_TYPE_EVENT) e_error_run (GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (gcal))), -- cgit v1.2.3