X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=src%2Fvnet%2Fmfib%2Fmfib_entry.c;h=79d2f9a50a30dd1a53e1e31944d0f0f3401481eb;hb=b7778b6310b57a13626041ed8613cea37d41c9ca;hp=ac37665fb723cc38f33631c10c9cbaa2b4c0995e;hpb=775f73c6baaf9bc2283e7ab9752c81984823be99;p=vpp.git diff --git a/src/vnet/mfib/mfib_entry.c b/src/vnet/mfib/mfib_entry.c index ac37665fb72..79d2f9a50a3 100644 --- a/src/vnet/mfib/mfib_entry.c +++ b/src/vnet/mfib/mfib_entry.c @@ -633,16 +633,25 @@ mfib_entry_stack (mfib_entry_t *mfib_entry, { /* * for exclusive routes the source provided a replicate DPO - * we we stashed inthe special path list with one path + * which we stashed in the special path list with one path, * so we can stack directly on that. */ ASSERT(1 == vec_len(ctx.next_hops)); - dpo_stack(DPO_MFIB_ENTRY, dp, - &mfib_entry->mfe_rep, - &ctx.next_hops[0].path_dpo); - dpo_reset(&ctx.next_hops[0].path_dpo); - vec_free(ctx.next_hops); + if (NULL != ctx.next_hops) + { + dpo_stack(DPO_MFIB_ENTRY, dp, + &mfib_entry->mfe_rep, + &ctx.next_hops[0].path_dpo); + dpo_reset(&ctx.next_hops[0].path_dpo); + vec_free(ctx.next_hops); + } + else + { + dpo_stack(DPO_MFIB_ENTRY, dp, + &mfib_entry->mfe_rep, + drop_dpo_get(dp)); + } } } else