bier - fix node table declaration 13/9413/3
authorGabriel Ganne <gabriel.ganne@enea.com>
Tue, 14 Nov 2017 13:43:34 +0000 (14:43 +0100)
committerNeale Ranns <nranns@cisco.com>
Tue, 14 Nov 2017 16:25:35 +0000 (16:25 +0000)
Need to be NULL-terminated.
Fix declarations of:
- bier_disp_table_bier_nodes
- bier_table_mpls_nodes
- bier_fmask_mpls_nodes

This was crashing during make test on aarch64 platform:
During the API call to bier_table_add_del, the crash happens during
dpo_default_get_next_node().

Change-Id: I16207ba38fc9ab65bad787878c4608740c312257
Signed-off-by: Gabriel Ganne <gabriel.ganne@enea.com>
src/vnet/bier/bier_disp_table.c
src/vnet/bier/bier_fmask.c
src/vnet/bier/bier_table.c

index 5caf86d..b2541da 100644 (file)
@@ -328,7 +328,8 @@ const static dpo_vft_t bier_disp_table_dpo_vft = {
 
 const static char *const bier_disp_table_bier_nodes[] =
 {
-    "bier-disp-lookup"
+    "bier-disp-lookup",
+    NULL
 };
 
 const static char * const * const bier_disp_table_nodes[DPO_PROTO_NUM] =
index e30425c..32bece0 100644 (file)
@@ -465,7 +465,8 @@ const static dpo_vft_t bier_fmask_dpo_vft = {
 
 const static char *const bier_fmask_mpls_nodes[] =
 {
-    "bier-output"
+    "bier-output",
+    NULL
 };
 const static char * const * const bier_fmask_nodes[DPO_PROTO_NUM] =
 {
index 74a0991..191ac01 100644 (file)
@@ -393,7 +393,8 @@ const static dpo_vft_t bier_table_dpo_vft = {
 
 const static char *const bier_table_mpls_nodes[] =
 {
-    "bier-input"
+    "bier-input",
+    NULL
 };
 const static char * const * const bier_table_nodes[DPO_PROTO_NUM] =
 {