1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2024-12-22 13:33:56 +03:00

sd-ndisc: ignore failure in sending solicitation

Even if a bonding master interface has carrier, the underlying slave
interfaces may not. In such a case, sending solicitation fails with
-ENOBUS. Here, let's unconditionally ignore errors, as anyway we will
send a solicitation later.

Fixes #24717.

(cherry picked from commit 852bf93826)
(cherry picked from commit d7b83b9986)
This commit is contained in:
Yu Watanabe 2022-10-11 16:19:12 +09:00 committed by Zbigniew Jędrzejewski-Szmek
parent 1316666e98
commit 950aa1d702

View File

@ -289,13 +289,12 @@ static int ndisc_timeout(sd_event_source *s, uint64_t usec, void *userdata) {
goto fail;
r = icmp6_send_router_solicitation(nd->fd, &nd->mac_addr);
if (r < 0) {
log_ndisc_errno(nd, r, "Error sending Router Solicitation: %m");
goto fail;
}
log_ndisc(nd, "Sent Router Solicitation, next solicitation in %s",
FORMAT_TIMESPAN(nd->retransmit_time, USEC_PER_SEC));
if (r < 0)
log_ndisc_errno(nd, r, "Failed to send Router Solicitation, next solicitation in %s, ignoring: %m",
FORMAT_TIMESPAN(nd->retransmit_time, USEC_PER_SEC));
else
log_ndisc(nd, "Sent Router Solicitation, next solicitation in %s",
FORMAT_TIMESPAN(nd->retransmit_time, USEC_PER_SEC));
return 0;