Add optional LWIP stack support
This commit is contained in:
parent
a937ff2d8d
commit
0fd822f913
18 changed files with 300 additions and 57 deletions
|
|
@ -31,7 +31,7 @@ func NewUDPForwarder(ctx context.Context, stack *stack.Stack, handler Handler, u
|
|||
ctx: ctx,
|
||||
stack: stack,
|
||||
handler: handler,
|
||||
udpNat: udpnat.New[netip.AddrPort](udpTimeout, nopErrorHandler{handler}),
|
||||
udpNat: udpnat.New[netip.AddrPort](udpTimeout, handler),
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -120,10 +120,3 @@ func (w *UDPBackWriter) WritePacket(buffer *buf.Buffer, destination M.Socksaddr)
|
|||
route.Stats().UDP.PacketsSent.Increment()
|
||||
return nil
|
||||
}
|
||||
|
||||
type nopErrorHandler struct {
|
||||
Handler
|
||||
}
|
||||
|
||||
func (h nopErrorHandler) NewError(ctx context.Context, err error) {
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue