update go.mod

This commit is contained in:
2024-03-10 14:10:01 +08:00
parent a81d74ac45
commit 48f630564f
6 changed files with 70 additions and 23 deletions
+2 -1
View File
@@ -6,6 +6,7 @@ import (
"context"
"errors"
"fmt"
"math"
"math/rand"
"net"
"os"
@@ -105,7 +106,7 @@ func (s *ServerCommon) Listen(network string, addr string) error {
return errors.New("server already run")
}
s.stopCtx, s.stopFn = context.WithCancel(context.Background())
s.queue = starnet.NewQueueCtx(s.stopCtx, 128)
s.queue = starnet.NewQueueCtx(s.stopCtx, 128, math.MaxUint32)
if strings.Contains(strings.ToLower(network), "udp") {
return s.ListenUDP(network, addr)
}