summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNelson Benitez Leon <nelsonjesus.benitez@seap.minhap.es>2012-03-14 12:11:43 +0100
committerJunio C Hamano <gitster@pobox.com>2012-03-15 13:48:08 -0700
commit72d62efe1c6044b25e2e3bdabde3eba2de75db48 (patch)
tree3c3636eea5451b55bfb1e81149e32417efa5139c
parent2217c38e5bdc2f8d8356f9a5560d0f2fd4e320c5 (diff)
downloadgit-nl/http-proxy-more.tar.gz
http: rename HTTP_REAUTH to HTTP_AUTH_RETRYnl/http-proxy-more
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_AUTH_RETRY. Signed-off-by: Nelson Benitez Leon <nbenitezl@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rw-r--r--http.c6
-rw-r--r--http.h2
2 files changed, 4 insertions, 4 deletions
diff --git a/http.c b/http.c
index e537031108..1c71edbfdb 100644
--- a/http.c
+++ b/http.c
@@ -840,7 +840,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_AUTH_RETRY;
}
} else if (results.http_code == 407) { /* Proxy authentication failure */
if (proxy_auth.username && proxy_auth.password) {
@@ -849,7 +849,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_AUTH_RETRY;
}
} else {
if (!curl_errorstr[0])
@@ -879,7 +879,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_AUTH_RETRY);
return ret;
}
diff --git a/http.h b/http.h
index 303eafbd2a..6e3ea594be 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_AUTH_RETRY 4
#define HTTP_NOAUTH 5
/*