-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added parsing of IPv6 addresses for incoming mDNS requests #990
Conversation
The idea SGTM, the new Someone familiar with the codebase needs to review this tho. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
log.Warning("Error parsing multiaddr from mdns entry: ", err) | ||
return | ||
} | ||
} else { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can deduplicate some of this code.
var addr net.IP
if e.AddrV4 != nil {
addr = e.AddrV4
} else if e.AddrV6 != nil {
addr = e.AddrV6
} else {
return some error
}
// construct the multiaddr
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
I want to have P2P communication fully based on IPv6, with local discovery using mDNS.
I am a beginner with libp2p so don't hesitate to bring your insights.