From cccf2de129da44c4ef33ecc2be7091c5edd41859 Mon Sep 17 00:00:00 2001 From: Anis Elleuch Date: Wed, 27 May 2020 02:03:00 +0100 Subject: [PATCH] madmin: Little error description when parsing server error msg (#9709) --- pkg/madmin/api-error-response.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/madmin/api-error-response.go b/pkg/madmin/api-error-response.go index c328c33f9..48cb779f1 100644 --- a/pkg/madmin/api-error-response.go +++ b/pkg/madmin/api-error-response.go @@ -18,6 +18,7 @@ package madmin import ( "encoding/xml" + "fmt" "net/http" ) @@ -70,7 +71,7 @@ func httpRespToErrorResponse(resp *http.Response) error { if err != nil { return ErrorResponse{ Code: resp.Status, - Message: "Failed to parse server response.", + Message: fmt.Sprintf("Failed to parse server response: %s.", err), } } closeResponse(resp)