X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=src%2Fvnet%2Ffib%2Ffib_entry.c;h=d7ff1c8c981c0e7f9c5a6a6a7885de0caae47bf3;hb=57b5860f013953ce161d05302e05370db9cd6ee2;hp=cdebfbce0a9b5ef810cd9319e26a05492496dd54;hpb=8142499cd1cb3b8d0168d0e6cf5309c5b4813cc4;p=vpp.git diff --git a/src/vnet/fib/fib_entry.c b/src/vnet/fib/fib_entry.c index cdebfbce0a9..d7ff1c8c981 100644 --- a/src/vnet/fib/fib_entry.c +++ b/src/vnet/fib/fib_entry.c @@ -462,11 +462,15 @@ fib_entry_get_adj (fib_node_index_t fib_entry_index) const dpo_id_t *dpo; dpo = fib_entry_contribute_ip_forwarding(fib_entry_index); - dpo = load_balance_get_bucket(dpo->dpoi_index, 0); - if (dpo_is_adj(dpo)) + if (dpo_id_is_valid(dpo)) { - return (dpo->dpoi_index); + dpo = load_balance_get_bucket(dpo->dpoi_index, 0); + + if (dpo_is_adj(dpo)) + { + return (dpo->dpoi_index); + } } return (ADJ_INDEX_INVALID); } @@ -1369,7 +1373,7 @@ fib_entry_is_resolved (fib_node_index_t fib_entry_index) if (NULL == fed) { /* - * no BFD tracking - resolved + * no BFD tracking - consider it resolved. */ return (!0); }