git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] Try an uppercase version of $prot_proxy env var

From
NLNelson Benitez Leon <nelsonjesus.benitez@seap.minhap.es>
Date
Apr 26, 2012, 13:16 UTC
Message-ID
<4F994AC3.2070708@seap.minhap.es>
In-Reply-To
<xmqqipgpgdpl.fsf@junio.mtv.corp.google.com>

Try an uppercase version of $prot_proxy env var when thelowercase version is not found.

Signed-off-by: Nelson Benitez Leon <nbenitezl@gmail.com>
---
This is for pu branch where http-proxy-more is located.
 http.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/http.c b/http.c
index 6a98195..bf9c20e 100644
--- a/http.c
+++ b/http.c
@@ -329,6 +329,13 @@ static CURL *get_curl_handle(const char *url)
 		strbuf_addf(&buf, "%s_proxy", cre_url.protocol);
 		env_proxy_var = strbuf_detach(&buf, NULL);
 		env_proxy = getenv(env_proxy_var);
+		if (!env_proxy) {
+			char *p;
+			for (p = env_proxy_var; *p; p++) {
+				*p = toupper(*p);
+			}
+			env_proxy = getenv(env_proxy_var);
+		}
 		if (env_proxy) {
 			read_http_proxy = 1;
 			no_proxy = getenv("no_proxy");
-- 
1.7.7.6
Previous: Junio C HamanoNext: Jeff King
Message 4 of 13 in “What's cooking in git.git (Apr 2012, #09; Mon, 23)”
  1. Junio C HamanoApr 23, 2012
  2. Nelson Benitez LeonApr 24, 2012
  3. Junio C HamanoApr 24, 2012
  4. Try an uppercase version of $prot_proxy env varNelson Benitez Leon, Apr 26, 2012
  5. Jeff KingApr 26, 2012
  6. Junio C HamanoApr 26, 2012
  7. Nelson Benitez LeonApr 26, 2012
  8. Jeff KingApr 27, 2012
  9. Junio C HamanoApr 27, 2012
  10. Junio C HamanoApr 26, 2012
  11. What's cooking (incremental)Junio C Hamano, Apr 25, 2012
  12. Thomas RastApr 25, 2012
  13. Junio C HamanoApr 25, 2012

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.