mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-03 10:30:22 +01:00
core: fix setting IPv6 default route
Seems that NLM_F_CREATE isn't enough, we need to replace anything that's already there. Oddly, this is even though we already cleaned out anything that was already there.
This commit is contained in:
parent
f96a42b0e2
commit
ddbb13bcc6
1 changed files with 1 additions and 1 deletions
|
|
@ -1167,7 +1167,7 @@ add_default_ip6_route (int ifindex, const struct in6_addr *gw, int mss)
|
|||
g_return_val_if_fail (route != NULL, -ENOMEM);
|
||||
|
||||
/* Add the new default route */
|
||||
err = nm_netlink_route6_add (route, &in6addr_any, 0, gw, NLM_F_CREATE);
|
||||
err = nm_netlink_route6_add (route, &in6addr_any, 0, gw, NLM_F_CREATE | NLM_F_REPLACE);
|
||||
if (err == -NLE_EXIST)
|
||||
err = 0;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue