summaryrefslogtreecommitdiff
path: root/src/network/networkd-ndisc.c
diff options
context:
space:
mode:
authorYu Watanabe <watanabe.yu+github@gmail.com>2021-05-19 11:30:35 +0900
committerYu Watanabe <watanabe.yu+github@gmail.com>2021-06-08 06:33:27 +0900
commit40b12fa20dcf8ae3138de4384a869a298a69ee19 (patch)
tree464b2ae4e6498517db07f9d04433f79f9e73931a /src/network/networkd-ndisc.c
parent5f33159190229099c9572a062f8996726225a1ac (diff)
downloadsystemd-40b12fa20dcf8ae3138de4384a869a298a69ee19.tar.gz
network: introduce request_hash_ops to dedup requests
If KeepConfiguration= or ConfigureWithoutCarrier= is set, then the same requests may be queued.
Diffstat (limited to 'src/network/networkd-ndisc.c')
-rw-r--r--src/network/networkd-ndisc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/network/networkd-ndisc.c b/src/network/networkd-ndisc.c
index 9ce579bfe5..80cb80247a 100644
--- a/src/network/networkd-ndisc.c
+++ b/src/network/networkd-ndisc.c
@@ -395,7 +395,7 @@ static int ndisc_request_route(Route *in, Link *link, sd_ndisc_router *rt) {
r = link_request_route(link, TAKE_PTR(route), true, &link->ndisc_routes_messages,
ndisc_route_handler, &req);
- if (r < 0)
+ if (r <= 0)
return r;
req->userdata = sd_ndisc_router_ref(rt);
@@ -507,7 +507,7 @@ static int ndisc_request_address(Address *in, Link *link, sd_ndisc_router *rt) {
r = link_request_address(link, TAKE_PTR(address), true, &link->ndisc_addresses_messages,
ndisc_address_handler, &req);
- if (r < 0)
+ if (r <= 0)
return r;
req->userdata = sd_ndisc_router_ref(rt);