aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/bfd/bfd_udp.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/vnet/bfd/bfd_udp.c')
-rw-r--r--src/vnet/bfd/bfd_udp.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/vnet/bfd/bfd_udp.c b/src/vnet/bfd/bfd_udp.c
index 37bb102d2d9..2ba43a309d1 100644
--- a/src/vnet/bfd/bfd_udp.c
+++ b/src/vnet/bfd/bfd_udp.c
@@ -42,6 +42,14 @@
#include <vnet/bfd/bfd_api.h>
#include <vnet/bfd/bfd.api_enum.h>
+#define F(sym, str) \
+ STATIC_ASSERT ((int) BFD_ERROR_##sym == (int) BFD_UDP_ERROR_##sym, \
+ "BFD error enums mismatch");
+foreach_bfd_error (F)
+#undef F
+ STATIC_ASSERT ((int) BFD_N_ERROR <= (int) BFD_UDP_N_ERROR,
+ "BFD error enum sizes mismatch");
+
typedef struct
{
bfd_main_t *bfd_main;