From 3ab623204be09f29dbf8de269f042dc66a4f63ee Mon Sep 17 00:00:00 2001 From: corvid Date: Tue, 12 Jan 2010 06:56:01 +0000 Subject: backout: That way would make no_proxy complicated. http://lists.auriga.wearlab.de/pipermail/dillo-dev/2010-January/007167.html --- src/IO/http.c | 6 ++---- src/prefs.c | 2 +- src/prefs.h | 2 +- src/prefsparser.cc | 2 +- 4 files changed, 5 insertions(+), 7 deletions(-) (limited to 'src') diff --git a/src/IO/http.c b/src/IO/http.c index afeb6d71..56a1b3a8 100644 --- a/src/IO/http.c +++ b/src/IO/http.c @@ -82,10 +82,8 @@ int a_Http_init(void) if (env_proxy && strlen(env_proxy)) HTTP_Proxy = a_Url_new(env_proxy, NULL); - if (!HTTP_Proxy && prefs.http_proxy) { - HTTP_Proxy = a_Url_new(prefs.http_proxy, NULL); - setenv("http_proxy", URL_STR(HTTP_Proxy), 1); - } + if (!HTTP_Proxy && prefs.http_proxy) + HTTP_Proxy = a_Url_dup(prefs.http_proxy); /* This allows for storing the proxy password in "user:passwd" format * in dillorc, but as this constitutes a security problem, it was disabled. diff --git a/src/prefs.c b/src/prefs.c index 615256de..e65d8e1a 100644 --- a/src/prefs.c +++ b/src/prefs.c @@ -104,7 +104,7 @@ void a_Prefs_freeall(void) dFree(prefs.font_serif); a_Url_free(prefs.home); dFree(prefs.http_language); - dFree(prefs.http_proxy); + a_Url_free(prefs.http_proxy); dFree(prefs.http_proxyuser); dFree(prefs.http_referer); dFree(prefs.no_proxy); diff --git a/src/prefs.h b/src/prefs.h index 463a0c8a..f3e0a977 100644 --- a/src/prefs.h +++ b/src/prefs.h @@ -34,7 +34,7 @@ struct _DilloPrefs { int xpos; int ypos; char *http_language; - char *http_proxy; + DilloUrl *http_proxy; char *http_proxyuser; char *http_referer; char *no_proxy; diff --git a/src/prefsparser.cc b/src/prefsparser.cc index 23876dd2..e77aecf6 100644 --- a/src/prefsparser.cc +++ b/src/prefsparser.cc @@ -63,7 +63,7 @@ int PrefsParser::parseOption(char *name, char *value) { "geometry", NULL, PREFS_GEOMETRY }, { "home", &prefs.home, PREFS_URL }, { "http_language", &prefs.http_language, PREFS_STRING }, - { "http_proxy", &prefs.http_proxy, PREFS_STRING }, + { "http_proxy", &prefs.http_proxy, PREFS_URL }, { "http_proxyuser", &prefs.http_proxyuser, PREFS_STRING }, { "http_referer", &prefs.http_referer, PREFS_STRING }, { "limit_text_width", &prefs.limit_text_width, PREFS_BOOL }, -- cgit v1.2.3