summaryrefslogtreecommitdiff
path: root/src/network/networkd-address.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/network/networkd-address.c')
-rw-r--r--src/network/networkd-address.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/network/networkd-address.c b/src/network/networkd-address.c
index 316ae2e4cb..f1b364f40e 100644
--- a/src/network/networkd-address.c
+++ b/src/network/networkd-address.c
@@ -283,11 +283,20 @@ static int address_release(Address *address, Link *link) {
}
int address_drop(Address *address) {
+ Link *link;
+ bool ready;
+
assert(address);
+ ready = address_is_ready(address);
+ link = address->link;
+
address_release(address, address->link);
address_free(address);
+ if (link && !ready)
+ link_check_ready(link);
+
return 0;
}