mirror of
https://github.com/v2fly/v2ray-core.git
synced 2025-07-25 11:14:26 -04:00
format code
This commit is contained in:
parent
2932d23b32
commit
edd02f7d3c
@ -128,7 +128,7 @@ func newBufferPool(bufferSize, poolSize int) *bufferPool {
|
|||||||
New: func() interface{} { return make([]byte, bufferSize) },
|
New: func() interface{} { return make([]byte, bufferSize) },
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
for i := 0; i < poolSize / 2; i++ {
|
for i := 0; i < poolSize/2; i++ {
|
||||||
pool.chain <- make([]byte, bufferSize)
|
pool.chain <- make([]byte, bufferSize)
|
||||||
}
|
}
|
||||||
return pool
|
return pool
|
||||||
|
@ -12,7 +12,7 @@ type Server struct {
|
|||||||
Port v2net.Port
|
Port v2net.Port
|
||||||
MsgProcessor func(msg []byte) []byte
|
MsgProcessor func(msg []byte) []byte
|
||||||
accepting bool
|
accepting bool
|
||||||
listener *net.TCPListener
|
listener *net.TCPListener
|
||||||
}
|
}
|
||||||
|
|
||||||
func (server *Server) Start() (v2net.Destination, error) {
|
func (server *Server) Start() (v2net.Destination, error) {
|
||||||
|
@ -11,7 +11,7 @@ type Server struct {
|
|||||||
Port v2net.Port
|
Port v2net.Port
|
||||||
MsgProcessor func(msg []byte) []byte
|
MsgProcessor func(msg []byte) []byte
|
||||||
accepting bool
|
accepting bool
|
||||||
conn *net.UDPConn
|
conn *net.UDPConn
|
||||||
}
|
}
|
||||||
|
|
||||||
func (server *Server) Start() (v2net.Destination, error) {
|
func (server *Server) Start() (v2net.Destination, error) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user