From 8383d528d982fdb746e939dfb9d170b53ef93f7b Mon Sep 17 00:00:00 2001 From: fatedier Date: Fri, 15 Mar 2024 14:22:03 +0800 Subject: [PATCH] disable quic-go's ECN support by default (#4069) --- Release.md | 1 + client/service.go | 4 ++++ server/service.go | 4 ++++ 3 files changed, 9 insertions(+) diff --git a/Release.md b/Release.md index 3f4af07..a699be8 100644 --- a/Release.md +++ b/Release.md @@ -1,3 +1,4 @@ ### Fixes * Fix the issue of incorrect interval time for rotating the log by day. +* Disable quic-go's ECN support by default. It may cause issues on certain operating systems. diff --git a/client/service.go b/client/service.go index e24e16d..7a7f6dc 100644 --- a/client/service.go +++ b/client/service.go @@ -43,6 +43,10 @@ func init() { crypto.DefaultSalt = "frp" // Disable quic-go's receive buffer warning. os.Setenv("QUIC_GO_DISABLE_RECEIVE_BUFFER_WARNING", "true") + // Disable quic-go's ECN support by default. It may cause issues on certain operating systems. + if os.Getenv("QUIC_GO_DISABLE_ECN") == "" { + os.Setenv("QUIC_GO_DISABLE_ECN", "true") + } } type cancelErr struct { diff --git a/server/service.go b/server/service.go index 4c3ee12..4fdb216 100644 --- a/server/service.go +++ b/server/service.go @@ -63,6 +63,10 @@ const ( func init() { // Disable quic-go's receive buffer warning. os.Setenv("QUIC_GO_DISABLE_RECEIVE_BUFFER_WARNING", "true") + // Disable quic-go's ECN support by default. It may cause issues on certain operating systems. + if os.Getenv("QUIC_GO_DISABLE_ECN") == "" { + os.Setenv("QUIC_GO_DISABLE_ECN", "true") + } } // Server service