From ed84473b7af96f4fc4d161bf60eeaa51bed7077b Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Tue, 24 Aug 2021 12:58:35 +0200 Subject: [PATCH] bridge: memset bst->config by default to avoid stale config values Signed-off-by: Felix Fietkau --- bridge.c | 1 + 1 file changed, 1 insertion(+) diff --git a/bridge.c b/bridge.c index 7acfb81..58e1b8b 100644 --- a/bridge.c +++ b/bridge.c @@ -998,6 +998,7 @@ bridge_apply_settings(struct bridge_state *bst, struct blob_attr **tb) struct blob_attr *cur; /* defaults */ + memset(cfg, 0, sizeof(*cfg)); cfg->stp = false; cfg->forward_delay = 2; cfg->robustness = 2; -- 2.30.2