diff options
Diffstat (limited to 'simulation/peer-server.go')
-rw-r--r-- | simulation/peer-server.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/simulation/peer-server.go b/simulation/peer-server.go index 4a74fb7..90bcf33 100644 --- a/simulation/peer-server.go +++ b/simulation/peer-server.go @@ -68,7 +68,7 @@ func (p *PeerServer) Run(configPath string) { defer p.peersMu.Unlock() host, _, _ := net.SplitHostPort(r.RemoteAddr) - p.peers[id] = fmt.Sprintf("%s:%s", host, portString) + p.peers[id] = net.JoinHostPort(host, portString) log.Printf("Peer %s joined from %s", id, p.peers[id]) } |