mirror of
https://github.com/golang/go
synced 2024-11-18 15:44:41 -07:00
net/http: remove unused switchReader type
Change-Id: Ic8a01d06ffc6c80beaf6dee9e7242dcbb7425e71 Reviewed-on: https://go-review.googlesource.com/3822 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This commit is contained in:
parent
5ae67e1e4e
commit
38dcc8cd88
@ -191,20 +191,14 @@ func (c *conn) noteClientGone() {
|
||||
c.clientGone = true
|
||||
}
|
||||
|
||||
// A switchReader can have its Reader changed at runtime.
|
||||
// It's not safe for concurrent Reads and switches.
|
||||
type switchReader struct {
|
||||
io.Reader
|
||||
}
|
||||
|
||||
// A switchWriter can have its Writer changed at runtime.
|
||||
// It's not safe for concurrent Writes and switches.
|
||||
type switchWriter struct {
|
||||
io.Writer
|
||||
}
|
||||
|
||||
// A liveSwitchReader is a switchReader that's safe for concurrent
|
||||
// reads and switches, if its mutex is held.
|
||||
// A liveSwitchReader can have its Reader changed at runtime. It's
|
||||
// safe for concurrent reads and switches, if its mutex is held.
|
||||
type liveSwitchReader struct {
|
||||
sync.Mutex
|
||||
r io.Reader
|
||||
|
Loading…
Reference in New Issue
Block a user