[zserv] Update interface flags to 8 bytes wide.
2006-01-11 Paul Jakma <paul.jakma@sun.com>
* if.h: (struct interface) expand flags to 8 bytes.
* zclient.c: (zebra_interface_{add,state}_read) stream read of
interface flags now need to use stream_getq.
(zebra_interface_if_set_value) ditto
2006-01-11 Paul Jakma <paul.jakma@sun.com>
* zserv.c: (zsend_interface_{add,delete,update}) if flags are
8 bytes now, update to write out with stream_putq.
diff --git a/lib/ChangeLog b/lib/ChangeLog
index da0bc4a..0e98b92 100644
--- a/lib/ChangeLog
+++ b/lib/ChangeLog
@@ -1,3 +1,10 @@
+2006-01-11 Paul Jakma <paul.jakma@sun.com>
+
+ * if.h: (struct interface) expand flags to 8 bytes.
+ * zclient.c: (zebra_interface_{add,state}_read) stream read of
+ interface flags now need to use stream_getq.
+ (zebra_interface_if_set_value) ditto
+
2006-01-10 Paul Jakma <paul.jakma@sun.com>
* stream.c: (stream_new) Allocate stream data as seperate object.
diff --git a/lib/if.h b/lib/if.h
index 8126ea9..e629906 100644
--- a/lib/if.h
+++ b/lib/if.h
@@ -92,7 +92,7 @@
#define ZEBRA_INTERFACE_LINKDETECTION (1 << 2)
/* Interface flags. */
- unsigned long flags;
+ uint64_t flags;
/* Interface metric */
int metric;
diff --git a/lib/zclient.c b/lib/zclient.c
index d0c4c3b..b09f558 100644
--- a/lib/zclient.c
+++ b/lib/zclient.c
@@ -585,6 +585,7 @@
* | ifindex |
* +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
* | if_flags |
+ * | |
* +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
* | metric |
* +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
@@ -615,7 +616,7 @@
/* Read interface's value. */
ifp->status = stream_getc (s);
- ifp->flags = stream_getl (s);
+ ifp->flags = stream_getq (s);
ifp->metric = stream_getl (s);
ifp->mtu = stream_getl (s);
ifp->mtu6 = stream_getl (s);
@@ -660,7 +661,7 @@
/* Read interface's value. */
ifp->status = stream_getc (s);
- ifp->flags = stream_getl (s);
+ ifp->flags = stream_getq (s);
ifp->metric = stream_getl (s);
ifp->mtu = stream_getl (s);
ifp->mtu6 = stream_getl (s);
@@ -709,7 +710,7 @@
ifp->status = stream_getc (s);
/* Read interface's value. */
- ifp->flags = stream_getl (s);
+ ifp->flags = stream_getq (s);
ifp->metric = stream_getl (s);
ifp->mtu = stream_getl (s);
ifp->mtu6 = stream_getl (s);
diff --git a/zebra/ChangeLog b/zebra/ChangeLog
index 89e5fca..91cf548 100644
--- a/zebra/ChangeLog
+++ b/zebra/ChangeLog
@@ -1,3 +1,8 @@
+2006-01-11 Paul Jakma <paul.jakma@sun.com>
+
+ * zserv.c: (zsend_interface_{add,delete,update}) if flags are
+ 8 bytes now, update to write out with stream_putq.
+
2005-12-29 Greg Troxel <gdt@fnord.ir.bbn.com>
* kernel_socket.c: remove dead code (from David Young).
diff --git a/zebra/zserv.c b/zebra/zserv.c
index abd99cd..35dd306 100644
--- a/zebra/zserv.c
+++ b/zebra/zserv.c
@@ -183,7 +183,7 @@
stream_put (s, ifp->name, INTERFACE_NAMSIZ);
stream_putl (s, ifp->ifindex);
stream_putc (s, ifp->status);
- stream_putl (s, ifp->flags);
+ stream_putq (s, ifp->flags);
stream_putl (s, ifp->metric);
stream_putl (s, ifp->mtu);
stream_putl (s, ifp->mtu6);
@@ -223,7 +223,7 @@
stream_put (s, ifp->name, INTERFACE_NAMSIZ);
stream_putl (s, ifp->ifindex);
stream_putc (s, ifp->status);
- stream_putl (s, ifp->flags);
+ stream_putq (s, ifp->flags);
stream_putl (s, ifp->metric);
stream_putl (s, ifp->mtu);
stream_putl (s, ifp->mtu6);
@@ -355,7 +355,7 @@
stream_put (s, ifp->name, INTERFACE_NAMSIZ);
stream_putl (s, ifp->ifindex);
stream_putc (s, ifp->status);
- stream_putl (s, ifp->flags);
+ stream_putq (s, ifp->flags);
stream_putl (s, ifp->metric);
stream_putl (s, ifp->mtu);
stream_putl (s, ifp->mtu6);