Commit 056145c
committed
net/http: deflake TestTransportRetryAfterGOAWAY
Drop a redundant Close of a net.Conn.
On Windows, writing to a closed connection will cause future
reads from the connection to fail, even if there is buffered
data available. When the test server writes a GOAWAY frame and
immediately closes the connection, this can result in the client
never seeing the GOAWAY. To avoid this, don't close server
connections until after all test functions have returned.
Fixes golang/go#59919
Change-Id: I82ed15870f3e6cd47f833a7a60b007b2fa2e15b0
Reviewed-on: https://go-review.googlesource.com/c/net/+/496056
TryBot-Result: Gopher Robot <[email protected]>
Run-TryBot: Damien Neil <[email protected]>
Reviewed-by: Bryan Mills <[email protected]>1 parent abee42a commit 056145c
1 file changed
+0
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3783 | 3783 | | |
3784 | 3784 | | |
3785 | 3785 | | |
3786 | | - | |
3787 | 3786 | | |
3788 | 3787 | | |
3789 | 3788 | | |
| |||
0 commit comments