mirror of
https://github.com/boringproxy/boringproxy.git
synced 2024-07-04 11:22:57 -05:00
Improve proxyConn comments
This commit is contained in:
parent
87cbeb4862
commit
ad6be0f6a9
7
sni.go
7
sni.go
|
@ -74,8 +74,11 @@ func (f *PassthroughListener) PassConn(conn net.Conn) {
|
|||
}
|
||||
|
||||
// This type creates a new net.Conn that's the same as an old one, except a new
|
||||
// reader is provided. So it proxies every method except Read. I'm sure there's
|
||||
// a cleaner way to do this...
|
||||
// reader is provided. So it proxies every method except Read. This is
|
||||
// necessary because by calling peekClientHello, part of the reader is read,
|
||||
// so we need to create a new reader with the already read data inserted back
|
||||
// in the front.
|
||||
// I'm sure there's a cleaner way to do this...
|
||||
type ProxyConn struct {
|
||||
conn net.Conn
|
||||
reader io.Reader
|
||||
|
|
Loading…
Reference in New Issue
Block a user