diff options
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/caldav/ChangeLog | 8 | ||||
-rw-r--r-- | plugins/caldav/caldav-source.c | 14 |
2 files changed, 21 insertions, 1 deletions
diff --git a/plugins/caldav/ChangeLog b/plugins/caldav/ChangeLog index 5f28deb6b3..9a9bae7398 100644 --- a/plugins/caldav/ChangeLog +++ b/plugins/caldav/ChangeLog @@ -1,3 +1,11 @@ +2009-04-28 Milan Crha <mcrha@redhat.com> + + ** Fix for bug #578335 + + * caldav-source.c: (user_changed), (location_changed): + Revert part of bug #562990, as EPassword requires username + as part of an URL to store passwords properly to a keyring. + 2009-04-24 Milan Crha <mcrha@redhat.com> ** Part of fix for bug #569652 diff --git a/plugins/caldav/caldav-source.c b/plugins/caldav/caldav-source.c index 46e510367f..5df807a691 100644 --- a/plugins/caldav/caldav-source.c +++ b/plugins/caldav/caldav-source.c @@ -124,11 +124,22 @@ location_changed (GtkEntry *editable, ESource *source) { EUri *euri; char *ruri; - const char *uri; + const char *uri, *username; uri = gtk_entry_get_text (GTK_ENTRY (editable)); euri = e_uri_new (uri); + g_return_if_fail (euri != NULL); + + username = e_source_get_property (source, "username"); + if (username && !*username) + username = NULL; + + if ((!euri->user && username) || (euri->user && username && !g_str_equal (euri->user, username))) { + g_free (euri->user); + euri->user = g_strdup (username); + } + ruri = print_uri_noproto (euri); e_source_set_relative_uri (source, ruri); g_free (ruri); @@ -163,6 +174,7 @@ user_changed (GtkEntry *editable, ESource *source) euri->user = NULL; if (user != NULL && *user) { + euri->user = g_strdup (user); e_source_set_property (source, "auth", "1"); } else { e_source_set_property (source, "auth", NULL); |