1
0
mirror of https://github.com/systemd/systemd.git synced 2024-11-06 08:26:52 +03:00

networkd: link - don't log errors when missing routes/addresses are dropped

We were ignoring the wrong errno.
This commit is contained in:
Tom Gundersen 2014-05-09 14:23:17 +02:00
parent 7619683b46
commit b90b025af1

View File

@ -420,7 +420,7 @@ static int route_drop_handler(sd_rtnl *rtnl, sd_rtnl_message *m, void *userdata)
} }
r = sd_rtnl_message_get_errno(m); r = sd_rtnl_message_get_errno(m);
if (r < 0 && r != -ENOENT) if (r < 0 && r != -ESRCH)
log_struct_link(LOG_WARNING, link, log_struct_link(LOG_WARNING, link,
"MESSAGE=%s: could not drop route: %s", "MESSAGE=%s: could not drop route: %s",
link->ifname, strerror(-r), link->ifname, strerror(-r),
@ -623,7 +623,7 @@ static int address_drop_handler(sd_rtnl *rtnl, sd_rtnl_message *m, void *userdat
} }
r = sd_rtnl_message_get_errno(m); r = sd_rtnl_message_get_errno(m);
if (r < 0 && r != -ENOENT) if (r < 0 && r != -EADDRNOTAVAIL)
log_struct_link(LOG_WARNING, link, log_struct_link(LOG_WARNING, link,
"MESSAGE=%s: could not drop address: %s", "MESSAGE=%s: could not drop address: %s",
link->ifname, strerror(-r), link->ifname, strerror(-r),