From a82d82e55914cbf11c6553abbeeea9ad64aba05d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=B8=96=E7=95=8C?= Date: Sun, 9 Apr 2023 22:50:25 +0800 Subject: [PATCH] Fix fallback packet conn --- common/bufio/fallback.go | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/common/bufio/fallback.go b/common/bufio/fallback.go index e54e862..4ea87cf 100644 --- a/common/bufio/fallback.go +++ b/common/bufio/fallback.go @@ -42,3 +42,15 @@ func (c *FallbackPacketConn) WriteTo(p []byte, addr net.Addr) (n int, err error) } return } + +func (c *FallbackPacketConn) ReaderReplaceable() bool { + return true +} + +func (c *FallbackPacketConn) WriterReplaceable() bool { + return true +} + +func (c *FallbackPacketConn) Upstream() any { + return c.PacketConn +}