summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--vnet/vnet/ip/lookup.c17
1 files changed, 8 insertions, 9 deletions
diff --git a/vnet/vnet/ip/lookup.c b/vnet/vnet/ip/lookup.c
index ebf2ba0cb18..8531f645629 100644
--- a/vnet/vnet/ip/lookup.c
+++ b/vnet/vnet/ip/lookup.c
@@ -1045,17 +1045,16 @@ u8 * format_ip_adjacency (u8 * s, va_list * args)
ip_adj_register_t *reg;
if (adj->lookup_next_index < vec_len (lm->registered_adjacencies))
- {
- reg = vec_elt_at_index(lm->registered_adjacencies,
- adj->lookup_next_index);
- if (reg->fn)
{
- s = format(s, " ");
- s = reg->fn(s, lm, adj);
- goto format_done;
+ reg = vec_elt_at_index(lm->registered_adjacencies,
+ adj->lookup_next_index);
+ if (reg->fn)
+ {
+ s = format(s, " %U", reg->fn, lm, adj);
+ goto format_done;
+ }
}
- }
-
+
switch (adj->lookup_next_index)
{
case IP_LOOKUP_NEXT_REWRITE: