mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-04 12:28:58 +00:00
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:
parent
428217f76c
commit
84b0fe8197
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=81959
@ -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; */
|
||||
|
Loading…
Reference in New Issue
Block a user