diff options
author | Andrea Barberio <insomniac@slackware.it> | 2019-04-29 13:52:22 +0100 |
---|---|---|
committer | insomniac <insomniacslk@users.noreply.github.com> | 2019-04-29 15:44:25 +0100 |
commit | 03e9ac918544b248cd2d660195934d7c943cb4d7 (patch) | |
tree | a9b43d893419db1d567934dc56f23b2eaaf16e0d /dhcpv6/async | |
parent | 5c6ea15a40cc06ac0af833fa3ef883de3f32037b (diff) |
[server6] Server should join multicast address
The previous logic was wrong - there's no "listening" on multicast
address, the server should listen on the given address, and join the
multicast group. This PR fixes it.
Also moved the multicast addresses to a common package.
Tested with unit/integ tests, and with coredhcp.
Signed-off-by: Andrea Barberio <insomniac@slackware.it>
Diffstat (limited to 'dhcpv6/async')
-rw-r--r-- | dhcpv6/async/client.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/dhcpv6/async/client.go b/dhcpv6/async/client.go index 4749e70..b2f977f 100644 --- a/dhcpv6/async/client.go +++ b/dhcpv6/async/client.go @@ -197,7 +197,7 @@ func (c *Client) receive(_ dhcpv6.DHCPv6) { func (c *Client) remoteAddr() (*net.UDPAddr, error) { if c.RemoteAddr == nil { - return &net.UDPAddr{IP: client6.AllDHCPRelayAgentsAndServers, Port: dhcpv6.DefaultServerPort}, nil + return &net.UDPAddr{IP: dhcpv6.AllDHCPRelayAgentsAndServers, Port: dhcpv6.DefaultServerPort}, nil } if addr, ok := c.RemoteAddr.(*net.UDPAddr); ok { |