mirror of
https://gitlab.torproject.org/tpo/anti-censorship/pluggable-transports/snowflake.git
synced 2025-10-13 20:11:19 -04:00
Store net.Addr in clientIDAddrMap
This fixes a stats collection bug where we were converting client addresses between a string and net.Addr using the clientAddr function multiple times, resulting in an empty string for all addresses.
This commit is contained in:
parent
aefabe683f
commit
6634f2bec9
4 changed files with 55 additions and 44 deletions
|
@ -138,7 +138,7 @@ func turbotunnelMode(conn net.Conn, addr net.Addr, pconn *turbotunnel.QueuePacke
|
|||
// recent WebSocket connection that has had to do with a session, at the
|
||||
// time the session is established, is the IP address that should be
|
||||
// credited for the entire KCP session.
|
||||
clientIDAddrMap.Set(clientID, addr.String())
|
||||
clientIDAddrMap.Set(clientID, addr)
|
||||
|
||||
var wg sync.WaitGroup
|
||||
wg.Add(2)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue