From ee167e524c6244b400045907c322862bb4f42c6c Mon Sep 17 00:00:00 2001 From: Matthew Smith Date: Thu, 2 Jul 2020 17:24:17 -0500 Subject: fib: fix debug preprocessor directives Type: fix Some debugging declarations were wrapped in an 'ifdef CLIB_DEBUG'. This seems to always evaluate true because clib.h defines CLIB_DEBUG to 0 if its not defined. The result is that if a route table is added and a route is added to it and then the table is deleted, VPP exits because the debug function fib_table_assert_empty() gets called whether VPP was started using a debug build or a release build. Change the ifdef to 'if CLIB_DEBUG > 0'. Change-Id: I357dc2c299e81b95244f2f7efaadb8e0de27627a Signed-off-by: Matthew Smith --- src/vnet/fib/fib_entry.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/vnet/fib/fib_entry.c') diff --git a/src/vnet/fib/fib_entry.c b/src/vnet/fib/fib_entry.c index 3bef28e3ad0..a8dec1a8c20 100644 --- a/src/vnet/fib/fib_entry.c +++ b/src/vnet/fib/fib_entry.c @@ -1713,7 +1713,7 @@ fib_entry_pool_size (void) return (pool_elts(fib_entry_pool)); } -#ifdef CLIB_DEBUG +#if CLIB_DEBUG > 0 void fib_table_assert_empty (const fib_table_t *fib_table) { -- cgit 1.2.3-korg