mirror of
https://github.com/systemd/systemd.git
synced 2025-01-25 10:04:04 +03:00
network: start dynamic addressing clients like DHCP after setting netdevs
The function link_acquire_conf() may make the link state 'configuring' when DHCP6 PD is enabled. Previously link_acquire_conf() was called before link_enter_join_netdev(), and thus the assertion in the function might be triggered. Fixes #17329.
This commit is contained in:
parent
a748b122be
commit
0e569a439a
@ -1758,6 +1758,11 @@ static int link_joined(Link *link) {
|
||||
return 0;
|
||||
|
||||
link_set_state(link, LINK_STATE_CONFIGURING);
|
||||
|
||||
r = link_acquire_conf(link);
|
||||
if (r < 0)
|
||||
return r;
|
||||
|
||||
return link_set_static_configs(link);
|
||||
}
|
||||
|
||||
@ -2038,12 +2043,6 @@ static int link_configure_continue(Link *link) {
|
||||
if (r < 0)
|
||||
log_link_warning_errno(link, r, "Cannot set IPv6 MTU for interface, ignoring: %m");
|
||||
|
||||
if (link_has_carrier(link) || link->network->configure_without_carrier) {
|
||||
r = link_acquire_conf(link);
|
||||
if (r < 0)
|
||||
return r;
|
||||
}
|
||||
|
||||
return link_enter_join_netdev(link);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user