device: don't add-and-activate dummy profiles with autoconf enabled

Let the default normalization from nm_connection_normalize() choose
'ipv6.method'. It will now choose "disabled" for dummy profiles, which
is just what we need.

In particular, we don't want to enable autoconf for dummy devices --
unless the profile which the user provides already has it enabled (in
which case nm_connection_normalize() doesn't change it).
This commit is contained in:
Thomas Haller 2021-07-02 13:59:18 +02:00
parent a32d04f0bb
commit e5484476f6
No known key found for this signature in database
GPG key ID: 29C2366E4DFC5728

View file

@ -50,15 +50,14 @@ complete_connection(NMDevice * device,
{
NMSettingDummy *s_dummy;
nm_utils_complete_generic(nm_device_get_platform(device),
connection,
NM_SETTING_DUMMY_SETTING_NAME,
existing_connections,
NULL,
_("Dummy connection"),
NULL,
nm_device_get_ip_iface(device),
TRUE);
nm_utils_complete_generic_with_params(nm_device_get_platform(device),
connection,
NM_SETTING_DUMMY_SETTING_NAME,
existing_connections,
NULL,
_("Dummy connection"),
NULL,
nm_device_get_ip_iface(device));
s_dummy = nm_connection_get_setting_dummy(connection);
if (!s_dummy) {