summaryrefslogtreecommitdiff
path: root/src/network/networkd-address.c
diff options
context:
space:
mode:
authorTom Gundersen <teg@jklm.no>2015-09-28 13:38:43 +0200
committerTom Gundersen <teg@jklm.no>2015-10-21 02:35:31 +0200
commit8012cd391932d58b44332df106d426a360faf0a6 (patch)
tree68dc497a0bc69291e7794b1d70a82196e5b7c8d8 /src/network/networkd-address.c
parentbf3ee9cdc9c7489e442e43cec09ad9275739875a (diff)
networkd: link - only consider configured when all addresses are ready
We were considering a link configured whilst its IPv6 addresses were still tentative. Fixes issue #650.
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;
}