summaryrefslogtreecommitdiff
path: root/libgo/go/net/http/response_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'libgo/go/net/http/response_test.go')
-rw-r--r--libgo/go/net/http/response_test.go6
1 files changed, 2 insertions, 4 deletions
diff --git a/libgo/go/net/http/response_test.go b/libgo/go/net/http/response_test.go
index e5d01698e55..165ec3624a4 100644
--- a/libgo/go/net/http/response_test.go
+++ b/libgo/go/net/http/response_test.go
@@ -321,9 +321,7 @@ func TestReadResponseCloseInMiddle(t *testing.T) {
}
if test.compressed {
buf.WriteString("Content-Encoding: gzip\r\n")
- var err error
- wr, err = gzip.NewWriter(wr)
- checkErr(err, "gzip.NewWriter")
+ wr = gzip.NewWriter(wr)
}
buf.WriteString("\r\n")
@@ -337,7 +335,7 @@ func TestReadResponseCloseInMiddle(t *testing.T) {
wr.Write(chunk)
}
if test.compressed {
- err := wr.(*gzip.Compressor).Close()
+ err := wr.(*gzip.Writer).Close()
checkErr(err, "compressor close")
}
if test.chunked {