summaryrefslogtreecommitdiffhomepage
path: root/bridge.c
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2020-08-07 12:07:53 +0200
committerFelix Fietkau <nbd@nbd.name>2020-08-07 12:08:42 +0200
commite32e21e8f338045f410293fab928c9166bf8a44e (patch)
tree6a5b0d0fe92940279340046031809a52c2ae37fa /bridge.c
parentac0710b7a3c6fc3b7b90d5ddc9a57b437e8e3ac5 (diff)
bridge: flush vlan list on bridge free
Fixes a potential memory leak Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'bridge.c')
-rw-r--r--bridge.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/bridge.c b/bridge.c
index c96dcc7..14d4972 100644
--- a/bridge.c
+++ b/bridge.c
@@ -665,6 +665,7 @@ bridge_free(struct device *dev)
bst = container_of(dev, struct bridge_state, dev);
vlist_flush_all(&bst->members);
+ vlist_flush_all(&dev->vlans);
free(bst->config_data);
free(bst);
}