Properly change old interface addresses so that their destination is

255.255.255.255 if our new destination address conflicts.
This commit is contained in:
Brian Somers 2001-08-20 11:06:21 +00:00
parent 428217f76c
commit 84b0fe8197
1 changed files with 2 additions and 1 deletions

View File

@ -421,7 +421,8 @@ iface_Add(struct iface *iface, struct ncp *ncp, const struct ncprange *ifa,
ncprange_getaddr(ifa, &ncplocal);
for (n = 0; n < iface->addrs; n++) {
if (ncprange_contains(&iface->addr[n].ifa, &ncplocal)) {
if (ncprange_contains(&iface->addr[n].ifa, &ncplocal) ||
ncpaddr_equal(&iface->addr[n].peer, peer)) {
if (!(how & IFACE_FORCE_ADD)) {
close(s);
return 0; /* errno = EEXIST; */