mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-05-04 21:08:04 +02:00
ifcfg-rh: change MACADDR_BLACKLIST to HWADDR_BLACKLIST (to correspond to HWADDR key)
This commit is contained in:
parent
b1afd46f65
commit
18b81930ce
2 changed files with 8 additions and 8 deletions
|
|
@ -2775,7 +2775,7 @@ make_wireless_setting (shvarFile *ifcfg,
|
|||
g_clear_error (error);
|
||||
}
|
||||
|
||||
value = svGetValue (ifcfg, "MACADDR_BLACKLIST", FALSE);
|
||||
value = svGetValue (ifcfg, "HWADDR_BLACKLIST", FALSE);
|
||||
if (value) {
|
||||
char **list = NULL, **iter;
|
||||
struct ether_addr addr;
|
||||
|
|
@ -2785,7 +2785,7 @@ make_wireless_setting (shvarFile *ifcfg,
|
|||
if (**iter == '\0')
|
||||
continue;
|
||||
if (!ether_aton_r (*iter, &addr)) {
|
||||
PLUGIN_WARN (IFCFG_PLUGIN_NAME, " warning: invalid MAC in MACADDR_BLACKLIST '%s'", *iter);
|
||||
PLUGIN_WARN (IFCFG_PLUGIN_NAME, " warning: invalid MAC in HWADDR_BLACKLIST '%s'", *iter);
|
||||
continue;
|
||||
}
|
||||
macaddr_blacklist = g_slist_prepend (macaddr_blacklist, *iter);
|
||||
|
|
@ -3195,7 +3195,7 @@ make_wired_setting (shvarFile *ifcfg,
|
|||
g_clear_error (error);
|
||||
}
|
||||
|
||||
value = svGetValue (ifcfg, "MACADDR_BLACKLIST", FALSE);
|
||||
value = svGetValue (ifcfg, "HWADDR_BLACKLIST", FALSE);
|
||||
if (value) {
|
||||
char **list = NULL, **iter;
|
||||
struct ether_addr addr;
|
||||
|
|
@ -3205,7 +3205,7 @@ make_wired_setting (shvarFile *ifcfg,
|
|||
if (**iter == '\0')
|
||||
continue;
|
||||
if (!ether_aton_r (*iter, &addr)) {
|
||||
PLUGIN_WARN (IFCFG_PLUGIN_NAME, " warning: invalid MAC in MACADDR_BLACKLIST '%s'", *iter);
|
||||
PLUGIN_WARN (IFCFG_PLUGIN_NAME, " warning: invalid MAC in HWADDR_BLACKLIST '%s'", *iter);
|
||||
continue;
|
||||
}
|
||||
macaddr_blacklist = g_slist_prepend (macaddr_blacklist, *iter);
|
||||
|
|
|
|||
|
|
@ -787,7 +787,7 @@ write_wireless_setting (NMConnection *connection,
|
|||
g_free (tmp);
|
||||
}
|
||||
|
||||
svSetValue (ifcfg, "MACADDR_BLACKLIST", NULL, FALSE);
|
||||
svSetValue (ifcfg, "HWADDR_BLACKLIST", NULL, FALSE);
|
||||
macaddr_blacklist = nm_setting_wireless_get_mac_address_blacklist (s_wireless);
|
||||
if (macaddr_blacklist) {
|
||||
const GSList *iter;
|
||||
|
|
@ -800,7 +800,7 @@ write_wireless_setting (NMConnection *connection,
|
|||
}
|
||||
if (blacklist_str->len > 0)
|
||||
g_string_truncate (blacklist_str, blacklist_str->len - 1);
|
||||
svSetValue (ifcfg, "MACADDR_BLACKLIST", blacklist_str->str, FALSE);
|
||||
svSetValue (ifcfg, "HWADDR_BLACKLIST", blacklist_str->str, FALSE);
|
||||
g_string_free (blacklist_str, TRUE);
|
||||
}
|
||||
|
||||
|
|
@ -980,7 +980,7 @@ write_wired_setting (NMConnection *connection, shvarFile *ifcfg, GError **error)
|
|||
g_free (tmp);
|
||||
}
|
||||
|
||||
svSetValue (ifcfg, "MACADDR_BLACKLIST", NULL, FALSE);
|
||||
svSetValue (ifcfg, "HWADDR_BLACKLIST", NULL, FALSE);
|
||||
macaddr_blacklist = nm_setting_wired_get_mac_address_blacklist (s_wired);
|
||||
if (macaddr_blacklist) {
|
||||
const GSList *iter;
|
||||
|
|
@ -993,7 +993,7 @@ write_wired_setting (NMConnection *connection, shvarFile *ifcfg, GError **error)
|
|||
}
|
||||
if (blacklist_str->len > 0)
|
||||
g_string_truncate (blacklist_str, blacklist_str->len - 1);
|
||||
svSetValue (ifcfg, "MACADDR_BLACKLIST", blacklist_str->str, FALSE);
|
||||
svSetValue (ifcfg, "HWADDR_BLACKLIST", blacklist_str->str, FALSE);
|
||||
g_string_free (blacklist_str, TRUE);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue