X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=src%2Fvnet%2Ffib%2Ffib_path_ext.c;h=209b6273a85c6247aa58f1fccac85a42b4dad507;hb=775f73c6b;hp=6b5b841c2ac9d2ef6ebf64a34dfbdacdd32fe715;hpb=31ed74407643595fdce206e9d7487108fb8b33ab;p=vpp.git diff --git a/src/vnet/fib/fib_path_ext.c b/src/vnet/fib/fib_path_ext.c index 6b5b841c2ac..209b6273a85 100644 --- a/src/vnet/fib/fib_path_ext.c +++ b/src/vnet/fib/fib_path_ext.c @@ -54,8 +54,7 @@ format_fib_path_ext (u8 * s, va_list * args) } s = format(s, "]"); } - s = format(s, " labels:[", - path_ext->fpe_path_index); + s = format(s, " labels:["); for (ii = 0; ii < vec_len(path_ext->fpe_path.frp_label_stack); ii++) { s = format(s, "[%U]", @@ -329,11 +328,14 @@ fib_path_ext_list_find_by_path_index (const fib_path_ext_list_t *list, { fib_path_ext_t *path_ext; - vec_foreach(path_ext, list->fpel_exts) + if (NULL != list) { - if (path_ext->fpe_path_index == path_index) + vec_foreach(path_ext, list->fpel_exts) { - return (path_ext); + if (path_ext->fpe_path_index == path_index) + { + return (path_ext); + } } } return (NULL);