chore: Generate UUID from fastrand

This commit is contained in:
H1JK
2023-03-05 11:00:14 +08:00
parent 3b037acb01
commit ae966833a4
11 changed files with 34 additions and 19 deletions

View File

@ -11,13 +11,14 @@ import (
"sync/atomic"
"time"
"github.com/gofrs/uuid"
"github.com/metacubex/quic-go"
N "github.com/Dreamacro/clash/common/net"
"github.com/Dreamacro/clash/common/pool"
"github.com/Dreamacro/clash/common/utils"
C "github.com/Dreamacro/clash/constant"
"github.com/Dreamacro/clash/transport/socks5"
"github.com/gofrs/uuid"
"github.com/metacubex/quic-go"
)
type ServerOption struct {
@ -55,7 +56,7 @@ func (s *Server) Serve() error {
return err
}
SetCongestionController(conn, s.CongestionController)
uuid, err := uuid.NewV4()
uuid, err := utils.UnsafeUUIDGenerator.NewV4()
if err != nil {
return err
}