aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/fib
diff options
context:
space:
mode:
authorNeale Ranns <nranns@cisco.com>2019-11-21 09:37:41 +0000
committerDamjan Marion <dmarion@me.com>2019-11-26 09:52:32 +0000
commit981a690b7d25c96ea56f95ece693377f95b93fc1 (patch)
tree4333a5d12d03d1f67bd280a64c7d29f7fc13ffe4 /src/vnet/fib
parent2b65f9ca04847b6e37861983183f5093b601fbb2 (diff)
fib: Another realloc burn
Type: fix harmless this time since it only affects the debug statement, but it still crashes an ASAN image. Signed-off-by: Neale Ranns <nranns@cisco.com> Change-Id: Ie02e7fe3014b98b9f8c83447f59017a380ab3948
Diffstat (limited to 'src/vnet/fib')
-rw-r--r--src/vnet/fib/fib_entry.c18
1 files changed, 13 insertions, 5 deletions
diff --git a/src/vnet/fib/fib_entry.c b/src/vnet/fib/fib_entry.c
index 833fcb33fcd..fd69db989f2 100644
--- a/src/vnet/fib/fib_entry.c
+++ b/src/vnet/fib/fib_entry.c
@@ -712,7 +712,7 @@ fib_entry_post_flag_update_actions (fib_entry_t *fib_entry,
return (fib_entry);
}
-static void
+static fib_entry_t*
fib_entry_post_install_actions (fib_entry_t *fib_entry,
fib_source_t source,
fib_entry_flag_t old_flags)
@@ -720,6 +720,8 @@ fib_entry_post_install_actions (fib_entry_t *fib_entry,
fib_entry = fib_entry_post_flag_update_actions(fib_entry,
old_flags);
fib_entry_src_action_installed(fib_entry, source);
+
+ return (fib_entry);
}
fib_node_index_t
@@ -754,7 +756,8 @@ fib_entry_create (u32 fib_index,
fib_entry = fib_entry_get(fib_entry_index);
fib_entry_src_action_activate(fib_entry, source);
- fib_entry_post_install_actions(fib_entry, source, FIB_ENTRY_FLAG_NONE);
+ fib_entry = fib_entry_post_install_actions(fib_entry, source,
+ FIB_ENTRY_FLAG_NONE);
FIB_ENTRY_DBG(fib_entry, "create");
@@ -782,7 +785,8 @@ fib_entry_create_special (u32 fib_index,
fib_entry = fib_entry_src_action_add(fib_entry, source, flags, dpo);
fib_entry_src_action_activate(fib_entry, source);
- fib_entry_post_install_actions(fib_entry, source, FIB_ENTRY_FLAG_NONE);
+ fib_entry = fib_entry_post_install_actions(fib_entry, source,
+ FIB_ENTRY_FLAG_NONE);
FIB_ENTRY_DBG(fib_entry, "create-special");
@@ -1308,7 +1312,9 @@ fib_entry_cover_changed (fib_node_index_t fib_entry_index)
fib_entry_src_action_reactivate(fib_entry,
fib_entry_src_get_source(
fib_entry_get_best_src_i(fib_entry)));
- fib_entry_post_install_actions(fib_entry, best_source, bflags);
+ fib_entry = fib_entry_post_install_actions(fib_entry,
+ best_source,
+ bflags);
}
else
{
@@ -1382,7 +1388,9 @@ fib_entry_cover_updated (fib_node_index_t fib_entry_index)
fib_entry_src_action_reactivate(fib_entry,
fib_entry_src_get_source(
fib_entry_get_best_src_i(fib_entry)));
- fib_entry_post_install_actions(fib_entry, best_source, bflags);
+ fib_entry = fib_entry_post_install_actions(fib_entry,
+ best_source,
+ bflags);
}
else
{