From 410ace5fad84c48973f381ad5ccd9d2e874c4ec2 Mon Sep 17 00:00:00 2001 From: Sarfraaz Ahmed Date: Fri, 30 Sep 2005 11:20:50 +0000 Subject: This now takes care to escape any auth mechanism in the uri. 2005-09-30 Sarfraaz Ahmed * gui/component/addressbook.c (remove_parameters_from_uri) : This now takes care to escape any auth mechanism in the uri. svn path=/trunk/; revision=30438 --- addressbook/ChangeLog | 5 +++++ addressbook/gui/component/addressbook.c | 16 ++++++++-------- 2 files changed, 13 insertions(+), 8 deletions(-) diff --git a/addressbook/ChangeLog b/addressbook/ChangeLog index 7e50851ec3..9d642c2758 100644 --- a/addressbook/ChangeLog +++ b/addressbook/ChangeLog @@ -1,3 +1,8 @@ +2005-09-30 Sarfraaz Ahmed + + * gui/component/addressbook.c (remove_parameters_from_uri) : This now + takes care to escape any auth mechanism in the uri. + 2005-09-30 Sushma Rai * importers/evolution-ldif-importer.c: Added some missing attrbutes and diff --git a/addressbook/gui/component/addressbook.c b/addressbook/gui/component/addressbook.c index 989efb216a..289a783da4 100644 --- a/addressbook/gui/component/addressbook.c +++ b/addressbook/gui/component/addressbook.c @@ -27,6 +27,7 @@ #include #include #include +#include #include #include "e-util/e-error.h" @@ -59,14 +60,13 @@ in uri*/ static gchar* remove_parameters_from_uri (const gchar *uri) { - gchar **components; - gchar *new_uri = NULL; - - components = g_strsplit (uri, ";", 2); - if (components[0]) - new_uri = g_strdup (components[0]); - g_strfreev (components); - return new_uri; + char *euri_str; + EUri *euri; + + euri = e_uri_new (uri); + euri_str = e_uri_to_string (euri, FALSE); + e_uri_free (euri); + return euri_str; } static void -- cgit v1.2.3