summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/network/networkd-manager.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/network/networkd-manager.c b/src/network/networkd-manager.c
index b2cb0fab4d..ddbdabbff9 100644
--- a/src/network/networkd-manager.c
+++ b/src/network/networkd-manager.c
@@ -145,13 +145,13 @@ void manager_free(Manager *m) {
sd_event_source_unref(m->sigint_event_source);
sd_event_unref(m->event);
- while ((network = m->networks))
- network_free(network);
-
while ((link = hashmap_first(m->links)))
link_free(link);
hashmap_free(m->links);
+ while ((network = m->networks))
+ network_free(network);
+
while ((netdev = hashmap_first(m->netdevs)))
netdev_free(netdev);
hashmap_free(m->netdevs);