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

[PATCH v4 5/5] http: rename HTTP_REAUTH to HTTP_RETRY

From
NLNelson Benitez Leon <nelsonjesus.benitez@seap.minhap.es>
Date
Mar 12, 2012, 17:30 UTC
Message-ID
<4F5E3298.5030502@seap.minhap.es>

After adding the proxy authentication support in http, the semantics of HTTP_REAUTH changed more to a retry rather than a re-authentication, so we rename it to HTTP_RETRY.

Signed-off-by: Nelson Benitez Leon <nbenitezl@gmail.com>
---
 http.c |    6 +++---
 http.h |    2 +-
 2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/http.c b/http.c
index 9b98179..4aa5a46 100644
--- a/http.c
+++ b/http.c
@@ -823,7 +823,7 @@ static int http_request(const char *url, void *result, int target, int options)
 			} else {
 				credential_fill(&http_auth);
 				init_curl_http_auth(slot->curl);
-				ret = HTTP_REAUTH;
+				ret = HTTP_RETRY;
 			}
 		} else if (results.http_code == 407) { /* Proxy authentication failure */
 			if (proxy_auth.username && proxy_auth.password) {
@@ -832,7 +832,7 @@ static int http_request(const char *url, void *result, int target, int options)
 			} else {
 				credential_fill(&proxy_auth);
 				set_proxy_auth(slot->curl);
-				ret = HTTP_REAUTH;
+				ret = HTTP_RETRY;
 			}
 		} else {
 			if (!curl_errorstr[0])
@@ -862,7 +862,7 @@ static int http_request_reauth(const char *url, void *result, int target,
 
 	do {
 		ret = http_request(url, result, target, options);
-	} while (ret == HTTP_REAUTH);
+	} while (ret == HTTP_RETRY);
 
 	return ret;
 }
diff --git a/http.h b/http.h
index 0b61653..6499397 100644
--- a/http.h
+++ b/http.h
@@ -123,7 +123,7 @@ extern char *get_remote_object_url(const char *url, const char *hex,
 #define HTTP_MISSING_TARGET	1
 #define HTTP_ERROR		2
 #define HTTP_START_FAILED	3
-#define HTTP_REAUTH	4
+#define HTTP_RETRY	4
 #define HTTP_NOAUTH	5
 
 /*
-- 
1.7.7.6
Next: Junio C Hamano
Message 1 of 8 in “http: rename HTTP_REAUTH to HTTP_RETRY”
  1. 5/5 http: rename HTTP_REAUTH to HTTP_RETRYNelson Benitez Leon, Mar 12, 2012
  2. Junio C HamanoMar 12, 2012
  3. Nelson Benitez LeonMar 13, 2012
  4. Junio C HamanoMar 13, 2012
  5. Jeff KingMar 13, 2012
  6. Junio C HamanoMar 13, 2012
  7. Nelson Benitez LeonMar 14, 2012
  8. Junio C HamanoMar 14, 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.