From 3b1caddd340b2e2ab4a9564e41285c7530aa85aa Mon Sep 17 00:00:00 2001 From: Rafael Zalamena Date: Wed, 9 Feb 2022 19:16:32 -0300 Subject: [PATCH] zebra: don't enqueue data with FPM socket closed It will trigger an assert while trying to schedule the next write. Signed-off-by: Rafael Zalamena --- zebra/dplane_fpm_nl.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/zebra/dplane_fpm_nl.c b/zebra/dplane_fpm_nl.c index 8c8004190b..4cd2bef307 100644 --- a/zebra/dplane_fpm_nl.c +++ b/zebra/dplane_fpm_nl.c @@ -1232,7 +1232,8 @@ static void fpm_process_queue(struct thread *t) * the output data in the STREAM_WRITEABLE * check above, so we can ignore the return */ - (void)fpm_nl_enqueue(fnc, ctx); + if (fnc->socket != -1) + (void)fpm_nl_enqueue(fnc, ctx); /* Account the processed entries. */ processed_contexts++; -- 2.39.5