zebra: Use the enum, luke

Use the enum and let the compiler help us figure out
what cases are being missed.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
This commit is contained in:
Donald Sharp 2022-11-14 08:06:16 -05:00
parent edb904e81c
commit dc31de93e1

View File

@ -1275,7 +1275,7 @@ static void fpm_process_queue(struct thread *t)
static void fpm_process_event(struct thread *t) static void fpm_process_event(struct thread *t)
{ {
struct fpm_nl_ctx *fnc = THREAD_ARG(t); struct fpm_nl_ctx *fnc = THREAD_ARG(t);
int event = THREAD_VAL(t); enum fpm_nl_events event = THREAD_VAL(t);
switch (event) { switch (event) {
case FNE_DISABLE: case FNE_DISABLE:
@ -1328,11 +1328,6 @@ static void fpm_process_event(struct thread *t)
if (IS_ZEBRA_DEBUG_FPM) if (IS_ZEBRA_DEBUG_FPM)
zlog_debug("%s: LSP walk finished", __func__); zlog_debug("%s: LSP walk finished", __func__);
break; break;
default:
if (IS_ZEBRA_DEBUG_FPM)
zlog_debug("%s: unhandled event %d", __func__, event);
break;
} }
} }