diff options
-rw-r--r-- | src/pkg/http/client.go | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/pkg/http/client.go b/src/pkg/http/client.go index 8af6c761f..8c2c30124 100644 --- a/src/pkg/http/client.go +++ b/src/pkg/http/client.go @@ -137,11 +137,13 @@ func Get(url string) (r *Response, finalURL string, err os.Error) { func Post(url string, bodyType string, body io.Reader) (r *Response, err os.Error) { var req Request req.Method = "POST" + req.ProtoMajor = 1 + req.ProtoMinor = 1 req.Body = nopCloser{body} req.Header = map[string]string{ "Content-Type": bodyType, - "Transfer-Encoding": "chunked", } + req.TransferEncoding = []string{"chunked"} req.URL, err = ParseURL(url) if err != nil { |