network: fix error aggregation in wwan_check_and_set_configuration()

When removing marked routes, the condition `if (ret)` incorrectly
overwrites any previously accumulated error in `ret` with the latest
return value `r`, even if `r >= 0` (success). This means an earlier
real error can be silently cleared by a subsequent successful
route_remove() call.

The parallel address_remove() block just above uses the correct
`if (r < 0)` pattern. Apply the same fix to the route_remove() block.
This commit is contained in:
noxiouz
2026-03-02 22:42:16 +00:00
committed by Yu Watanabe
parent 66a43b02e6
commit fbf533859f

View File

@@ -529,7 +529,7 @@ static int link_apply_bearer_impl(Link *link, Bearer *b) {
continue;
r = route_remove(route, link->manager);
if (ret)
if (r < 0)
ret = r;
}