aboutsummaryrefslogtreecommitdiffstats
path: root/composer
diff options
context:
space:
mode:
authorMilan Crha <mcrha@redhat.com>2010-04-19 19:18:50 +0800
committerMilan Crha <mcrha@redhat.com>2010-04-19 19:18:50 +0800
commit24a269487823900e491cafd76af2c973f34898fb (patch)
treec657a27139c23ef14882af74187c402ef73faa8c /composer
parent5974489593515109b910f3becfb87672cdd2086c (diff)
downloadgsoc2013-evolution-24a269487823900e491cafd76af2c973f34898fb.tar
gsoc2013-evolution-24a269487823900e491cafd76af2c973f34898fb.tar.gz
gsoc2013-evolution-24a269487823900e491cafd76af2c973f34898fb.tar.bz2
gsoc2013-evolution-24a269487823900e491cafd76af2c973f34898fb.tar.lz
gsoc2013-evolution-24a269487823900e491cafd76af2c973f34898fb.tar.xz
gsoc2013-evolution-24a269487823900e491cafd76af2c973f34898fb.tar.zst
gsoc2013-evolution-24a269487823900e491cafd76af2c973f34898fb.zip
Bug #494047 - Unescape uris in composer's Post-To
Diffstat (limited to 'composer')
-rw-r--r--composer/e-composer-post-header.c16
1 files changed, 13 insertions, 3 deletions
diff --git a/composer/e-composer-post-header.c b/composer/e-composer-post-header.c
index 7fd26aa8a7..5bace17d4d 100644
--- a/composer/e-composer-post-header.c
+++ b/composer/e-composer-post-header.c
@@ -45,16 +45,26 @@ static gchar *
composer_post_header_folder_name_to_string (EComposerPostHeader *header,
const gchar *url)
{
+ gchar *res = NULL;
const gchar *base_url = header->priv->base_url;
if (base_url != NULL) {
gsize length = strlen (base_url);
- if (g_ascii_strncasecmp (url, base_url, length) == 0)
- return g_strdup (url + length);
+ if (g_ascii_strncasecmp (url, base_url, length) == 0) {
+ res = g_uri_unescape_string (url + length, NULL);
+ if (!res)
+ res = g_strdup (url + length);
+ }
+ }
+
+ if (!res) {
+ res = g_uri_unescape_string (url, NULL);
+ if (!res)
+ res = g_strdup (url);
}
- return g_strdup (url);
+ return res;
}
static void