chore: update math/rand to math/rand/v2

This commit is contained in:
nadoo committed 2025-02-28 00:40:20 +08:00
1 parent 8e81e09a8f
commit 6aee7b35c0
22 files changed
+75 -80

No files matched your search

+1 -4
View File
@@ -64,10 +64,7 @@ func (c *TLSObfsConn) Write(b []byte) (int, error) {
n := len(b)
for i := 0; i < n; i += chunkSize {
buf.Reset()
end := i + chunkSize
if end > n {
end = n
}
end := min(i+chunkSize, n)
buf.Write([]byte{0x17, 0x03, 0x03})
binary.Write(buf, binary.BigEndian, uint16(len(b[i:end])))