修复节点UDP小时的问题

This commit is contained in:
CN-JS-HuiBai
2026-04-17 19:29:17 +08:00
parent faeeb9bc3c
commit 35631da799
3 changed files with 4 additions and 4 deletions

View File

@@ -91,7 +91,7 @@ func (l *Listener) Start() error {
return err
}
l.packetOutboundClosed = make(chan struct{})
l.packetOutbound = make(chan *N.PacketBuffer, 64)
l.packetOutbound = make(chan *N.PacketBuffer, 1024)
go l.loopUDPIn()
if !l.disablePacketOutput {
go l.loopUDPOut()

View File

@@ -198,7 +198,7 @@ func (w *packetWriter) WritePacket(buffer *buf.Buffer, destination M.Socksaddr)
if w.shutdown.Load() {
return os.ErrClosed
}
w.logger.Trace("dropped packet to ", destination)
w.logger.Debug("dropped packet to ", destination)
return nil
}
}

View File

@@ -30,6 +30,6 @@ var ProtocolTimeouts = map[string]time.Duration{
ProtocolDNS: 10 * time.Second,
ProtocolNTP: 10 * time.Second,
ProtocolSTUN: 10 * time.Second,
ProtocolQUIC: 30 * time.Second,
ProtocolDTLS: 30 * time.Second,
ProtocolQUIC: 60 * time.Second,
ProtocolDTLS: 60 * time.Second,
}