summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorpaul <paul>2004-08-25 13:47:16 +0000
committerpaul <paul>2004-08-25 13:47:16 +0000
commitefba6ce941fb96763d5804212a674ca6b7098853 (patch)
tree84538f4f9fa888a11838333bb6df029181d00cd5 /lib
parentb094d2603158f9d514404941c9fad04dd9b7d42c (diff)
2004-08-19 Paul Jakma <paul@dishone.st>
* zebra.h: add MAX and MIN defines (eg for ospf6d)
Diffstat (limited to 'lib')
-rw-r--r--lib/ChangeLog4
-rw-r--r--lib/zebra.h11
2 files changed, 14 insertions, 1 deletions
diff --git a/lib/ChangeLog b/lib/ChangeLog
index 0e1960b1..514f47a1 100644
--- a/lib/ChangeLog
+++ b/lib/ChangeLog
@@ -1,5 +1,9 @@
2004-08-19 Paul Jakma <paul@dishone.st>
+ * zebra.h: add MAX and MIN defines (eg for ospf6d)
+
+2004-08-19 Paul Jakma <paul@dishone.st>
+
* sockopt.c: include sockopt.h
rename some of the _pktinfo_ functions to _ifindex, where that is
their purpose.
diff --git a/lib/zebra.h b/lib/zebra.h
index 89e07dea..6412655c 100644
--- a/lib/zebra.h
+++ b/lib/zebra.h
@@ -245,6 +245,14 @@ struct in_pktinfo
};
#endif
+/* MAX / MIN are not commonly defined, but useful */
+#ifndef MAX
+#define MAX(a, b) ((a) > (b) ? (a) : (b))
+#endif
+#ifndef MIN
+#define MIN(a, b) ((a) < (b) ? (a) : (b))
+#endif
+
/* For old definition. */
#ifndef IN6_ARE_ADDR_EQUAL
#define IN6_ARE_ADDR_EQUAL IN6_IS_ADDR_EQUAL
@@ -269,7 +277,8 @@ struct in_pktinfo
#define ZEBRA_IPV6_NEXTHOP_LOOKUP 16
#define ZEBRA_IPV4_IMPORT_LOOKUP 17
#define ZEBRA_IPV6_IMPORT_LOOKUP 18
-#define ZEBRA_MESSAGE_MAX 19
+#define ZEBRA_INTERFACE_RENAME 19
+#define ZEBRA_MESSAGE_MAX 20
/* Zebra route's types. */
#define ZEBRA_ROUTE_SYSTEM 0