summaryrefslogtreecommitdiff
path: root/zebra/ioctl_solaris.c
diff options
context:
space:
mode:
authorPaul Jakma <paul.jakma@sun.com>2007-04-10 19:43:43 +0000
committerPaul Jakma <paul.jakma@sun.com>2007-04-10 19:43:43 +0000
commitf5e004f74fecaf84b50f8c1823432077ad7e15b7 (patch)
treebffb42983f6b993c861ac67192646ed82db9fc1f /zebra/ioctl_solaris.c
parent6e4ab12f1504caa95edc7702a82f118d0de15a0a (diff)
[zebra] MTU change should propogate to zserv client on BSD/Solaris
2007-04-10 Paul Jakma <paul.jakma@sun.com> * ioctl{_solaris,}.c: (if_get_mtu) Ping clients via zebra_interface_up_update if MTU is changed.
Diffstat (limited to 'zebra/ioctl_solaris.c')
-rw-r--r--zebra/ioctl_solaris.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/zebra/ioctl_solaris.c b/zebra/ioctl_solaris.c
index 2f05bf12..f68ea56e 100644
--- a/zebra/ioctl_solaris.c
+++ b/zebra/ioctl_solaris.c
@@ -156,6 +156,7 @@ if_get_mtu (struct interface *ifp)
{
struct lifreq lifreq;
int ret;
+ u_char changed = 0;
if (ifp->flags & IFF_IPV4)
{
@@ -170,12 +171,17 @@ if_get_mtu (struct interface *ifp)
else
{
ifp->mtu = lifreq.lifr_metric;
+ changed = 1;
}
}
#ifdef HAVE_IPV6
if ((ifp->flags & IFF_IPV6) == 0)
- return;
+ {
+ if (changed)
+ zebra_interface_up_update(ifp);
+ return;
+ }
memset(&lifreq, 0, sizeof(lifreq));
lifreq_set_name (&lifreq, ifp->name);
@@ -189,7 +195,11 @@ if_get_mtu (struct interface *ifp)
else
{
ifp->mtu6 = lifreq.lifr_metric;
+ changed = 1
}
+
+ if (changed)
+ zebra_interface_up_update(ifp);
#endif /* HAVE_IPV6 */
}