diff options
author | Tom Gundersen <teg@jklm.no> | 2015-02-04 10:08:12 +0100 |
---|---|---|
committer | Tom Gundersen <teg@jklm.no> | 2015-02-05 11:50:34 +0100 |
commit | 6a24f1484fcc1f59f89617afbe4282667a358eab (patch) | |
tree | c0a1d3b5d0d9b44e958c135456df730359aa6c03 /src/network/networkd-manager.c | |
parent | 73432d67b590c8c8954cf2f8954d174a55d58c7b (diff) |
networkd: don't warn about missing links unnecessarily
If we get a NEWLINK + NEWADDR between enumerating the links and enumerating the addresses, we
would get a warning that the link corresponding to the address does not exist. This is a false
warning as both the NEWLINK and NEWADDR would be processed after enumerating completed, so drop
it.
Diffstat (limited to 'src/network/networkd-manager.c')
-rw-r--r-- | src/network/networkd-manager.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/network/networkd-manager.c b/src/network/networkd-manager.c index 378633061e..4d27272b3b 100644 --- a/src/network/networkd-manager.c +++ b/src/network/networkd-manager.c @@ -525,9 +525,13 @@ int manager_rtnl_enumerate_links(Manager *m) { for (link = reply; link; link = sd_rtnl_message_next(link)) { int k; + m->enumerating = true; + k = manager_rtnl_process_link(m->rtnl, link, m); if (k < 0) r = k; + + m->enumerating = false; } return r; @@ -556,9 +560,13 @@ int manager_rtnl_enumerate_addresses(Manager *m) { for (addr = reply; addr; addr = sd_rtnl_message_next(addr)) { int k; + m->enumerating = true; + k = link_rtnl_process_address(m->rtnl, addr, m); if (k < 0) r = k; + + m->enumerating = false; } return r; |