Skip to content

Commit

Permalink
home: imp code
Browse files Browse the repository at this point in the history
  • Loading branch information
ainar-g committed Mar 22, 2021
1 parent 2b4a28c commit a18c3f0
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions internal/home/dns.go
Original file line number Diff line number Diff line change
Expand Up @@ -115,9 +115,9 @@ func ipsToTCPAddrs(ips []net.IP, port int) (tcpAddrs []*net.TCPAddr) {
}

tcpAddrs = make([]*net.TCPAddr, len(ips))
for i := range tcpAddrs {
for i, ip := range ips {
tcpAddrs[i] = &net.TCPAddr{
IP: ips[i],
IP: ip,
Port: port,
}
}
Expand All @@ -131,9 +131,9 @@ func ipsToUDPAddrs(ips []net.IP, port int) (udpAddrs []*net.UDPAddr) {
}

udpAddrs = make([]*net.UDPAddr, len(ips))
for i := range udpAddrs {
for i, ip := range ips {
udpAddrs[i] = &net.UDPAddr{
IP: ips[i],
IP: ip,
Port: port,
}
}
Expand Down

0 comments on commit a18c3f0

Please sign in to comment.