Modify IPv4 vip addrs' broadaddr from `x.x.x.255` to `x.x.x.x`, same as

vip addr, because vips' netmask only support `255.255.255.255` now.
This commit is contained in:
fengbojiang 2024-09-06 12:59:47 +08:00
parent 1023238cee
commit f4e3243725
1 changed files with 2 additions and 2 deletions

View File

@ -466,8 +466,8 @@ ff_veth_setvaddr(struct ff_veth_softc *sc, struct ff_port_cfg *cfg)
sa.sin_addr.s_addr = 0xFFFFFFFF;
bcopy(&sa, &req.ifra_mask, sizeof(sa));
// Only support 'x.x.x.255' broadaddr now
sa.sin_addr.s_addr = sc->vip[i] | 0xFF000000;
// Only support 'x.x.x.x' broadaddr now
sa.sin_addr.s_addr = sc->vip[i] /*| 0xFF000000*/;
bcopy(&sa, &req.ifra_broadaddr, sizeof(sa));
ret = ifioctl(so, SIOCAIFADDR, (caddr_t)&req, curthread);