summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/vnet/fib/fib_entry.c5
-rw-r--r--src/vnet/fib/fib_table.c2
2 files changed, 5 insertions, 2 deletions
diff --git a/src/vnet/fib/fib_entry.c b/src/vnet/fib/fib_entry.c
index 3aa3632c596..8ef4ea898f4 100644
--- a/src/vnet/fib/fib_entry.c
+++ b/src/vnet/fib/fib_entry.c
@@ -1426,7 +1426,10 @@ fib_entry_encode (fib_node_index_t fib_entry_index,
fib_entry_t *fib_entry;
fib_entry = fib_entry_get(fib_entry_index);
- fib_path_list_walk(fib_entry->fe_parent, fib_path_encode, api_rpaths);
+ if (FIB_NODE_INDEX_INVALID != fib_entry->fe_parent)
+ {
+ fib_path_list_walk(fib_entry->fe_parent, fib_path_encode, api_rpaths);
+ }
}
void
diff --git a/src/vnet/fib/fib_table.c b/src/vnet/fib/fib_table.c
index f997335a9f2..a0ce0bbb4de 100644
--- a/src/vnet/fib/fib_table.c
+++ b/src/vnet/fib/fib_table.c
@@ -1162,7 +1162,7 @@ fib_table_flush (u32 fib_index,
vec_foreach(fib_entry_index, ctx.ftf_entries)
{
- fib_entry_delete(*fib_entry_index, source);
+ fib_table_entry_delete_index(*fib_entry_index, source);
}
vec_free(ctx.ftf_entries);