[evolution/foocanvas] Bug #494047 - Unescape uris in composer's Post-To
- From: Henning Habighorst <hhabig src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution/foocanvas] Bug #494047 - Unescape uris in composer's Post-To
- Date: Sun, 25 Apr 2010 20:59:49 +0000 (UTC)
commit ea7609ca0f905fa721b0a9950a37ab114492eb34
Author: Milan Crha <mcrha redhat com>
Date: Mon Apr 19 13:18:50 2010 +0200
Bug #494047 - Unescape uris in composer's Post-To
composer/e-composer-post-header.c | 16 +++++++++++++---
1 files changed, 13 insertions(+), 3 deletions(-)
---
diff --git a/composer/e-composer-post-header.c b/composer/e-composer-post-header.c
index 7fd26aa..5bace17 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
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]