From: Jeonghyun Yun Date: Mon, 23 Oct 2017 11:44:18 +0000 (+0900) Subject: elm_url: matched between url and proxy environment X-Git-Tag: submit/tizen/20171025.103743~4 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=68d114e4bd8e5fc594e6685ca8b275a46f450958;p=platform%2Fupstream%2Felementary.git elm_url: matched between url and proxy environment @tizen_fix Change-Id: Ic46db15739a1c86d39b223aa47cf114d52419f3e Signed-off-by: Jeonghyun Yun --- diff --git a/src/lib/elm_url.c b/src/lib/elm_url.c index 95d38010d..847f708e2 100644 --- a/src/lib/elm_url.c +++ b/src/lib/elm_url.c @@ -102,9 +102,23 @@ _elm_url_download(const char *url, Elm_Url_Done done_cb, Elm_Url_Cancel cancel_c if (getuid() == geteuid()) #endif { - if (getenv("http_proxy")) ecore_con_url_proxy_set(target, getenv("http_proxy")); + //TIZEN ONLY (20171023): matched between url and proxy environment + /*if (getenv("http_proxy")) ecore_con_url_proxy_set(target, getenv("http_proxy")); if (getenv("https_proxy")) ecore_con_url_proxy_set(target, getenv("https_proxy")); - if (getenv("ftp_proxy")) ecore_con_url_proxy_set(target, getenv("ftp_proxy")); + if (getenv("ftp_proxy")) ecore_con_url_proxy_set(target, getenv("ftp_proxy"));*/ + if ((!strncmp(url, "http://", strlen("http://"))) && (getenv("http_proxy"))) + { + ecore_con_url_proxy_set(target, getenv("http_proxy")); + } + else if ((!strncmp(url, "https://", strlen("https://"))) && (getenv("https_proxy"))) + { + ecore_con_url_proxy_set(target, getenv("https_proxy")); + } + else if ((!strncmp(url, "ftp://", strlen("ftp://"))) && (getenv("ftp_proxy"))) + { + ecore_con_url_proxy_set(target, getenv("ftp_proxy")); + } + // } r = malloc(sizeof (Elm_Url));