This commit is contained in:
Jason
2019-08-11 21:11:08 +08:00
parent 6d50f90315
commit c22db614ff
2 changed files with 12 additions and 10 deletions

View File

@@ -3,8 +3,6 @@ package socks
import (
"net"
"time"
"github.com/xjasonlyu/tun2socks/common/log"
)
type duplexConn interface {
@@ -15,14 +13,12 @@ type duplexConn interface {
func tcpCloseRead(conn net.Conn) {
if c, ok := conn.(duplexConn); ok {
log.Warnf("ok!----")
c.CloseRead()
}
}
func tcpCloseWrite(conn net.Conn) {
if c, ok := conn.(duplexConn); ok {
log.Warnf("ok!++++")
c.CloseWrite()
}
}