From: Jeff King Date: Fri, 5 Apr 2013 22:22:01 +0000 (-0400) Subject: http: re-word http error message X-Git-Tag: v1.8.3-rc0~73^2~2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=39a570f26c953e8277a6a26c00da657b240dcdd4;p=thirdparty%2Fgit.git http: re-word http error message When we report an http error code, we say something like: error: The requested URL reported failure: 403 Forbidden while accessing http://example.com/repo.git Everything between "error:" and "while" is written by curl, and the resulting sentence is hard to read (especially because there is no punctuation between curl's sentence and the remainder of ours). Instead, let's re-order this to give better flow: error: unable to access 'http://example.com/repo.git: The requested URL reported failure: 403 Forbidden This is still annoyingly long, but at least reads more clearly left to right. Signed-off-by: Jeff King Signed-off-by: Junio C Hamano --- diff --git a/http.c b/http.c index 5e6f67d004..64068a2fc7 100644 --- a/http.c +++ b/http.c @@ -943,7 +943,7 @@ cleanup: void http_error(const char *url) { - error("%s while accessing %s", curl_errorstr, url); + error("unable to access '%s': %s", url, curl_errorstr); } int http_fetch_ref(const char *base, struct ref *ref)