mirror of
https://gitlab.labs.nic.cz/labs/bird.git
synced 2024-05-11 16:54:54 +00:00
Fix behavior of ipa_opposite().
It was giving wrong results on /30 networks.
This commit is contained in:
@@ -377,7 +377,7 @@ nl_parse_addr(struct nlmsghdr *h)
|
||||
ifa.brd = ipa_or(ifa.ip, ipa_not(netmask));
|
||||
#ifndef IPV6
|
||||
if (i->ifa_prefixlen == BITS_PER_IP_ADDRESS - 2)
|
||||
ifa.opposite = ipa_opposite(ifa.ip);
|
||||
ifa.opposite = ipa_opposite(ifa.ip, i->ifa_prefixlen);
|
||||
if ((ifi->flags & IF_BROADCAST) && a[IFA_BROADCAST])
|
||||
{
|
||||
memcpy(&xbrd, RTA_DATA(a[IFA_BROADCAST]), sizeof(xbrd));
|
||||
|
Reference in New Issue
Block a user