Skip peers that don't resolve
This commit is contained in:
parent
677e5592e5
commit
a70dea7b39
2 changed files with 3 additions and 1 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -21,3 +21,4 @@
|
||||||
# Go workspace file
|
# Go workspace file
|
||||||
go.work
|
go.work
|
||||||
|
|
||||||
|
jrouter-prod.yaml
|
||||||
|
|
3
main.go
3
main.go
|
@ -154,7 +154,8 @@ func main() {
|
||||||
|
|
||||||
raddr, err := net.ResolveUDPAddr("udp4", peerStr)
|
raddr, err := net.ResolveUDPAddr("udp4", peerStr)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Fatalf("Invalid UDP address: %v", err)
|
log.Printf("couldn't resolve UDP address, skipping: %v", err)
|
||||||
|
continue
|
||||||
}
|
}
|
||||||
log.Printf("resolved %q to %v", peerStr, raddr)
|
log.Printf("resolved %q to %v", peerStr, raddr)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue