mirror of
https://github.com/xjasonlyu/tun2socks.git
synced 2025-10-12 12:10:21 +08:00
Chore(iobased): use MTU()
This commit is contained in:
@@ -56,7 +56,7 @@ func (e *Endpoint) IsAttached() bool {
|
||||
// dispatchLoop dispatches packets to upper layer.
|
||||
func (e *Endpoint) dispatchLoop() {
|
||||
for {
|
||||
packet := make([]byte, e.mtu)
|
||||
packet := make([]byte, e.MTU())
|
||||
|
||||
n, err := e.rw.Read(packet)
|
||||
if err != nil {
|
||||
|
Reference in New Issue
Block a user