summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--zebra/rt_netlink.c16
1 files changed, 15 insertions, 1 deletions
diff --git a/zebra/rt_netlink.c b/zebra/rt_netlink.c
index c487b1da..c6ec08c6 100644
--- a/zebra/rt_netlink.c
+++ b/zebra/rt_netlink.c
@@ -985,7 +985,21 @@ netlink_link_change (struct sockaddr_nl *snl, struct nlmsghdr *h)
zlog_info ("interface %s index %d changed %s.",
name, ifi->ifi_index, if_flag_dump(new_flags));
- if_flags_update(ifp, new_flags);
+ if (if_is_operative (ifp))
+ {
+ ifp->flags = new_flags;
+ if (!if_is_operative (ifp))
+ if_down (ifp);
+ else
+ /* Must notify client daemons of new interface status. */
+ zebra_interface_up_update (ifp);
+ }
+ else
+ {
+ ifp->flags = new_flags;
+ if (if_is_operative (ifp))
+ if_up (ifp);
+ }
}
}
}