[zebra] Fix interface metric bug on BSD
2007-03-06 Paul Jakma <paul.jakma@sun.com>
* kernel_socket.c: (ifam_read) Do not update interface metric on
receipt of NEW/DEL ADDR messages, bogus as: a) some systems
dont include iface metric for address events b) we didn't
update clients either. Initial diagnosis by Eugene Grosbein.
diff --git a/zebra/ChangeLog b/zebra/ChangeLog
index 7bdec92..97dcd5f 100644
--- a/zebra/ChangeLog
+++ b/zebra/ChangeLog
@@ -1,3 +1,10 @@
+2007-03-06 Paul Jakma <paul.jakma@sun.com>
+
+ * kernel_socket.c: (ifam_read) Do not update interface metric on
+ receipt of NEW/DEL ADDR messages, bogus as: a) some systems
+ dont include iface metric for address events b) we didn't
+ update clients either. Initial diagnosis by Eugene Grosbein.
+
2007-02-26 Robert Olsson <Robert.Olsson@data.slu.se>
* irdp_main.c: (irdp_send_thread) Skip non-AF_INET addresses,
diff --git a/zebra/kernel_socket.c b/zebra/kernel_socket.c
index ac06566..5281236 100644
--- a/zebra/kernel_socket.c
+++ b/zebra/kernel_socket.c
@@ -585,8 +585,15 @@
if (ifnlen && strncmp (ifp->name, ifname, INTERFACE_NAMSIZ))
isalias = 1;
+#if 0
+ /* it might seem cute to grab the interface metric here, however
+ * we're processing an address update message, and so some systems
+ * (e.g. FBSD) dont bother to fill in ifam_metric. Disabled, but left
+ * in deliberately, as comment.
+ */
ifp->metric = ifam->ifam_metric;
-
+#endif
+
/* Add connected address. */
switch (sockunion_family (&addr))
{