summaryrefslogtreecommitdiff
path: root/internal/httpclient/client.go
diff options
context:
space:
mode:
Diffstat (limited to 'internal/httpclient/client.go')
-rw-r--r--internal/httpclient/client.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/internal/httpclient/client.go b/internal/httpclient/client.go
index ffaf76537..fd70cca7e 100644
--- a/internal/httpclient/client.go
+++ b/internal/httpclient/client.go
@@ -247,8 +247,8 @@ func (c *Client) DoSigned(r *http.Request, sign SignFunc) (rsp *http.Response, e
// Rewind body reader and content-length if set.
if rc, ok := r.Body.(*byteutil.ReadNopCloser); ok {
+ rc.Rewind() // set len AFTER rewind
r.ContentLength = int64(rc.Len())
- rc.Rewind()
}
// Sign the outgoing request.