diff options
author | ru <ru@FreeBSD.org> | 2000-01-25 12:24:06 +0000 |
---|---|---|
committer | ru <ru@FreeBSD.org> | 2000-01-25 12:24:06 +0000 |
commit | b1253d64a8435ad53086b8e1905dddb81514ba76 (patch) | |
tree | 4e7f5088d68cce034daa1b2b17b6be92964faee1 /sbin/natd/natd.c | |
parent | dd64f33471b6d8023bd7dac582b2a0b0dd273e97 (diff) | |
download | FreeBSD-src-b1253d64a8435ad53086b8e1905dddb81514ba76.zip FreeBSD-src-b1253d64a8435ad53086b8e1905dddb81514ba76.tar.gz |
Now that kernel is capable of notifying user processes about
the interface MTU change (src/sys/net/if_sl.c,v 1.83), track
interface MTU with -dynamic option as well.
PR: 15494
Diffstat (limited to 'sbin/natd/natd.c')
-rw-r--r-- | sbin/natd/natd.c | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/sbin/natd/natd.c b/sbin/natd/natd.c index 3d6c856..09cd257 100644 --- a/sbin/natd/natd.c +++ b/sbin/natd/natd.c @@ -640,16 +640,14 @@ static void HandleRoutingInfo (int fd) } if (verbose) - printf ("Routing message %X received.\n", ifMsg.ifm_type); + printf ("Routing message %#x received.\n", ifMsg.ifm_type); - if (ifMsg.ifm_type != RTM_NEWADDR) - return; - - if (verbose && ifMsg.ifm_index == ifIndex) - printf ("Interface address has changed.\n"); - - if (ifMsg.ifm_index == ifIndex) + if ((ifMsg.ifm_type == RTM_NEWADDR || ifMsg.ifm_type == RTM_IFINFO) && + ifMsg.ifm_index == ifIndex) { + if (verbose) + printf("Interface address/MTU has probably changed.\n"); assignAliasAddr = 1; + } } static void PrintPacket (struct ip* ip) |