~ubuntu-branches/ubuntu/oneiric/libubuntuone/oneiric

« back to all changes in this revision

Viewing changes to debian/patches/trunk_fix_escaping.patch

  • Committer: Package Import Robot
  • Author(s): Sebastien Bacher
  • Date: 2011-09-30 21:17:57 UTC
  • Revision ID: package-import@ubuntu.com-20110930211757-slmwtb0vychr2vxj
Tags: 0.11.0-0ubuntu2
Backport upstream r138 to fix store urls escaping issues (lp: #863176)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
=== modified file 'libubuntuone/u1-music-store.c'
 
2
--- libubuntuone/u1-music-store.c       2011-09-09 15:11:47 +0000
 
3
+++ libubuntuone/u1-music-store.c       2011-09-30 10:54:34 +0000
 
4
@@ -1425,7 +1425,7 @@
 
5
 void
 
6
 u1_music_store_load_store_link (U1MusicStore *music_store, const gchar *url)
 
7
 {
 
8
-       gchar *real_url, *oauth_consumer_token, *oauth_consumer_secret, *oauth_token, *oauth_token_secret;
 
9
+       gchar *real_url, *oauth_consumer_token, *oauth_consumer_secret, *oauth_token, *oauth_token_secret, *quoted_url;
 
10
 
 
11
        g_return_if_fail (U1_IS_MUSIC_STORE (music_store));
 
12
        g_return_if_fail (url != NULL);
 
13
@@ -1436,10 +1436,12 @@
 
14
                music_store->priv->idle_cb = 0;
 
15
        }
 
16
 
 
17
+       quoted_url = g_uri_escape_string (url, NULL, FALSE);
 
18
        real_url = g_strdup_printf ("%s%s?forward_on_to_url=%s",
 
19
                                    music_store->priv->base_url,
 
20
                                    U1_STORE_URL,
 
21
-                                   url);
 
22
+                                   quoted_url);
 
23
+       g_free (quoted_url);
 
24
 
 
25
        /* Sign the URL if we have OAuth tokens */
 
26
        get_credentials (music_store,
 
27