diff options
author | brian <brian@FreeBSD.org> | 1998-10-26 19:07:36 +0000 |
---|---|---|
committer | brian <brian@FreeBSD.org> | 1998-10-26 19:07:36 +0000 |
commit | 54882479aee399667951dbeca252bd5961bd7bd6 (patch) | |
tree | cf6312c9b39d37fdfa2224df915dde9095a1410b /lib/libc/regex/regexec.c | |
parent | de27adfbe9a0cf1453956685ae2a84b1ff7e9947 (diff) | |
download | FreeBSD-src-54882479aee399667951dbeca252bd5961bd7bd6.zip FreeBSD-src-54882479aee399667951dbeca252bd5961bd7bd6.tar.gz |
Fix the interface alias code. Previously, I was expecting something
like
tun0: flags=blah
10.0.0.1 -> 10.0.0.100
10.0.0.2 -> 10.0.0.100
10.0.0.3 -> 10.0.0.100
to DTRT, despite the SIOCAIFADDR for each new alias returning
-1 & EEXIST while adding the alias anyway. In real life, once
we have the second alias with the same destination, nothing will
route any more ! Also, because I was ignoring EEXIST, the
dynamic IP assignment code was assigning duplicate addresses
('cos it was being lied to by iface_inAdd()).
Now we have
tun0: flags=blah
10.0.0.1 -> 255.255.255.255
10.0.0.2 -> 10.0.0.100
10.0.0.3 -> 255.255.255.255
This works - stuff bound to 10.1 & 10.3 will be considered alive
by the kernel, and when they route back to the tun device, the
packets get aliased to 10.2 and go out to 10.100 (as with the
original plan).
We still see the EEXIST in SIOCAIFADDR, but ignore it when our
destination is 255.255.255.255, assuming that the alias *was*
actually added.
Additionally, ``iface add'' may now optionally be given only
the interface address. The mask & destination default to
255.255.255.255.
Diffstat (limited to 'lib/libc/regex/regexec.c')
0 files changed, 0 insertions, 0 deletions