mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-06 16:40:16 +01:00
core/dhcp-manager: warn if dhclient plugin is requested
It's deprecated. Warn any time it is being considered for loading, instead of at load time, so that the user gets a warning when they got the plugin in configuration, even if it's build time disabled. https://issues.redhat.com/browse/RHEL-24622
This commit is contained in:
parent
bc5d76ca82
commit
3955be817d
1 changed files with 9 additions and 2 deletions
|
|
@ -90,8 +90,15 @@ _client_factory_find_by_name(const char *name)
|
|||
static const NMDhcpClientFactory *
|
||||
_client_factory_available(const NMDhcpClientFactory *client_factory)
|
||||
{
|
||||
if (client_factory && (!client_factory->get_path || client_factory->get_path()))
|
||||
return client_factory;
|
||||
if (client_factory) {
|
||||
if (nm_streq(client_factory->name, "dhclient")) {
|
||||
_LOGW(AF_UNSPEC,
|
||||
"attempting to used a deprecated DHCP client '%s' ",
|
||||
client_factory->name);
|
||||
}
|
||||
if (!client_factory->get_path || client_factory->get_path())
|
||||
return client_factory;
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue