mirror of
https://github.com/xiaoqidun/probe.git
synced 2026-01-29 04:58:46 +08:00
fix(修复功能): 修复IPv6支持
This commit is contained in:
+3
-1
@@ -103,7 +103,9 @@ func performTest(conn net.PacketConn, serverAddr string, network string, timeout
|
||||
return nil, nil, err
|
||||
}
|
||||
txID := [12]byte{}
|
||||
rand.Read(txID[:])
|
||||
if _, err := rand.Read(txID[:]); err != nil {
|
||||
return nil, nil, err
|
||||
}
|
||||
req := encodeSTUNRequest(txID, changeIP, changePort)
|
||||
if _, err := conn.WriteTo(req, dst); err != nil {
|
||||
return nil, nil, err
|
||||
|
||||
Reference in New Issue
Block a user