Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(5)

Issue 87550045: code review 87550045: net/http: clarify Response.Body Close responsibility (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 1 month ago by bradfitz
Modified:
11 years, 1 month ago
Reviewers:
gobot, rsc
CC:
golang-codereviews, rsc, adg, dsymonds, r
Visibility:
Public.

Description

net/http: clarify Response.Body Close responsibility Per TODO email in my inbox.

Patch Set 1 #

Patch Set 2 : diff -r f8ac12d0acae https://go.googlecode.com/hg/ #

Patch Set 3 : diff -r f8ac12d0acae https://go.googlecode.com/hg/ #

Total comments: 1

Patch Set 4 : diff -r f8ac12d0acae https://go.googlecode.com/hg/ #

Patch Set 5 : diff -r 14e22539ebfd https://go.googlecode.com/hg/ #

Unified diffs Side-by-side diffs Delta from patch set Stats (+2 lines, -1 line) Patch
M src/pkg/net/http/response.go View 1 2 3 1 chunk +2 lines, -1 line 0 comments Download

Messages

Total messages: 12
bradfitz
Hello golang-codereviews@googlegroups.com (cc: adg@golang.org, dsymonds@golang.org, r@golang.org, rsc@golang.org), I'd like you to review this change to ...
11 years, 1 month ago (2014-04-14 20:18:20 UTC) #1
rsc
Doesn't 'done reading from it' imply the rest?
11 years, 1 month ago (2014-04-14 20:20:12 UTC) #2
bradfitz
No. If I read just that, I could believe that an error from Read was ...
11 years, 1 month ago (2014-04-14 20:22:14 UTC) #3
rsc
okay, how about "It is the caller's responsibility to close the Body."
11 years, 1 month ago (2014-04-14 21:02:05 UTC) #4
rsc
actually, this sentence seems like it is in the wrong place. this is describing a ...
11 years, 1 month ago (2014-04-14 21:02:30 UTC) #5
bradfitz
I want something here because people look here for guidance and people have asked me ...
11 years, 1 month ago (2014-04-14 21:11:39 UTC) #6
rsc
https://codereview.appspot.com/87550045/diff/40001/src/pkg/net/http/response.go File src/pkg/net/http/response.go (right): https://codereview.appspot.com/87550045/diff/40001/src/pkg/net/http/response.go#newcode50 src/pkg/net/http/response.go:50: // a zero-lengthed body. s/lengthed/length/ and then put the ...
11 years, 1 month ago (2014-04-14 22:58:08 UTC) #7
bradfitz
Hello golang-codereviews@googlegroups.com, rsc@golang.org (cc: adg@golang.org, dsymonds@golang.org, golang-codereviews@googlegroups.com, r@golang.org), Please take another look.
11 years, 1 month ago (2014-04-14 23:01:58 UTC) #8
rsc
LGTM
11 years, 1 month ago (2014-04-14 23:48:02 UTC) #9
bradfitz
*** Submitted as https://code.google.com/p/go/source/detail?r=15c88860a91c *** net/http: clarify Response.Body Close responsibility Per TODO email in my ...
11 years, 1 month ago (2014-04-14 23:50:23 UTC) #10
gobot
This CL appears to have broken the linux-386-387 builder. See http://build.golang.org/log/ede7e12362a941d93bf1fe21db9208a3e298029e
11 years, 1 month ago (2014-04-15 00:01:42 UTC) #11
bradfitz
11 years, 1 month ago (2014-04-15 00:03:07 UTC) #12
Btw, this failure:

--- FAIL: TestPipeLookPathLeak (0.09 seconds)
exec_test.go:228: leaked 4 fds; want ~0
2014/04/14 23:59:28 http: TLS handshake error from 127.0.0.1:36251: remote
error: bad certificate
FAIL
FAIL os/exec 0.981s

Is about that "leaked 4 fds" line.  The line after it is expected noise.  I
can shut it up.

But there's still a leak.



On Mon, Apr 14, 2014 at 5:01 PM, <gobot@golang.org> wrote:

> This CL appears to have broken the linux-386-387 builder.
> See http://build.golang.org/log/ede7e12362a941d93bf1fe21db9208a3e298029e
>
> https://codereview.appspot.com/87550045/
>
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b