Mercurial > pidgin-twitter
comparison icon.c @ 323:6ebabb96485f
try g_uri_escape_string() instead of picky purple_url_encode().
author | Yoshiki Yazawa <yaz@honeyplanet.jp> |
---|---|
date | Sat, 19 Sep 2009 03:43:23 +0900 |
parents | f021bd3431a6 |
children | 5e0c1f59a090 |
comparison
equal
deleted
inserted
replaced
322:6be85af48b6b | 323:6ebabb96485f |
---|---|
245 gchar *slash = strrchr(url, '/'); | 245 gchar *slash = strrchr(url, '/'); |
246 *slash = '\0'; | 246 *slash = '\0'; |
247 | 247 |
248 gchar *tmp; | 248 gchar *tmp; |
249 /* url encode basename. twitter needs this. */ | 249 /* url encode basename. twitter needs this. */ |
250 if(service == twitter_service) | 250 #if 0 |
251 if(service == twitter_service) | |
251 tmp = g_strdup_printf("%s/%s", url, | 252 tmp = g_strdup_printf("%s/%s", url, |
252 purple_url_encode(slash+1)); | 253 purple_url_encode(slash+1)); |
254 #else | |
255 if(service == twitter_service) { | |
256 gchar *tmp0 = g_uri_escape_string(slash+1, NULL, FALSE); | |
257 tmp = g_strdup_printf("%s/%s", url, tmp0); | |
258 g_free(tmp0); | |
259 } | |
260 #endif | |
253 else if(service == wassr_service) { | 261 else if(service == wassr_service) { |
254 gchar *tmp0 = NULL; | 262 gchar *tmp0 = NULL; |
255 tmp0 = g_regex_replace(regp[SIZE_128_WASSR], slash+1, | 263 tmp0 = g_regex_replace(regp[SIZE_128_WASSR], slash+1, |
256 -1, 0, ".64.", 0, NULL); | 264 -1, 0, ".64.", 0, NULL); |
257 tmp = g_strdup_printf("http://wassr.jp%s/%s", url, | 265 tmp = g_strdup_printf("http://wassr.jp%s/%s", url, |