Sat, 19 Nov 2005 13:56:22 +0000
[gaim-migrate @ 14457]
Unleaky the gnome proxy things
| src/proxy.c | file | annotate | diff | comparison | revisions |
--- a/src/proxy.c Sat Nov 19 13:53:09 2005 +0000 +++ b/src/proxy.c Sat Nov 19 13:56:22 2005 +0000 @@ -190,7 +190,9 @@ gchar *path; if ((path = g_find_program_in_path("gconftool-2"))) { gchar *tmp; - + + g_free(path); + /* See whether to use a proxy. */ if (!g_spawn_command_line_sync("gconftool-2 -g /system/http_proxy/use_http_proxy", &tmp, NULL, NULL, NULL)) @@ -200,10 +202,10 @@ g_free(tmp); return gaim_global_proxy_get_info(); } - + g_free(tmp); info.type = GAIM_PROXY_HTTP; - + /* Free the old fields */ if (info.host) { g_free(info.host); @@ -217,13 +219,13 @@ g_free(info.password); info.password = NULL; } - + /* Get the new ones */ if (!g_spawn_command_line_sync("gconftool-2 -g /system/http_proxy/host", &info.host, NULL, NULL, NULL)) return gaim_global_proxy_get_info(); g_strchomp(info.host); - + if (!g_spawn_command_line_sync("gconftool-2 -g /system/http_proxy/authentication_user", &info.username, NULL, NULL, NULL)) return gaim_global_proxy_get_info(); @@ -238,8 +240,8 @@ NULL, NULL, NULL)) return gaim_global_proxy_get_info(); info.port = atoi(tmp); + g_free(tmp); - g_free(path); return &info; } return gaim_global_proxy_get_info();