diff options
| author | David du Colombier <0intro@gmail.com> | 2016-11-12 22:12:22 +0100 |
|---|---|---|
| committer | David du Colombier <0intro@gmail.com> | 2016-11-12 21:23:04 +0000 |
| commit | 4bee9012b31a762799ea861cd5f55583f1f602f5 (patch) | |
| tree | abedf08115b53d6c0806fb8c6b6f5d3e52791d48 /src/net/http/httptest | |
| parent | 091ba60bd87bf8b40a24196f31b5f3c18c2f2dc4 (diff) | |
| download | go-4bee9012b31a762799ea861cd5f55583f1f602f5.tar.xz | |
net/http/httptest: remove workaround on Plan 9
This issue has been fixed in CL 31390.
Change-Id: I0c2425fd33be878037d10d612a50116a7b693431
Reviewed-on: https://go-review.googlesource.com/33195
Run-TryBot: David du Colombier <0intro@gmail.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Diffstat (limited to 'src/net/http/httptest')
| -rw-r--r-- | src/net/http/httptest/server.go | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/src/net/http/httptest/server.go b/src/net/http/httptest/server.go index e67b7145be..711821433b 100644 --- a/src/net/http/httptest/server.go +++ b/src/net/http/httptest/server.go @@ -16,7 +16,6 @@ import ( "net/http" "net/http/internal" "os" - "runtime" "sync" "time" ) @@ -294,15 +293,6 @@ func (s *Server) closeConn(c net.Conn) { s.closeConnChan(c, nil) } // closeConnChan is like closeConn, but takes an optional channel to receive a value // when the goroutine closing c is done. func (s *Server) closeConnChan(c net.Conn, done chan<- struct{}) { - if runtime.GOOS == "plan9" { - // Go's Plan 9 net package isn't great at unblocking reads when - // their underlying TCP connections are closed. Don't trust - // that that the ConnState state machine will get to - // StateClosed. Instead, just go there directly. Plan 9 may leak - // resources if the syscall doesn't end up returning. Oh well. - s.forgetConn(c) - } - c.Close() if done != nil { done <- struct{}{} |
