mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-05-07 06:08:02 +02:00
device: improve error message for failure to reapply
(cherry picked from commit c71bd9df82)
This commit is contained in:
parent
16d0cc332a
commit
4a1b7f40c6
1 changed files with 14 additions and 7 deletions
|
|
@ -7183,13 +7183,20 @@ _hash_check_invalid_keys_impl (GHashTable *hash, const char *setting_name, GErro
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
g_set_error (error,
|
if (setting_name) {
|
||||||
NM_DEVICE_ERROR,
|
g_set_error (error,
|
||||||
NM_DEVICE_ERROR_INCOMPATIBLE_CONNECTION,
|
NM_DEVICE_ERROR,
|
||||||
"Can't reapply changes to '%s%s%s' setting",
|
NM_DEVICE_ERROR_INCOMPATIBLE_CONNECTION,
|
||||||
setting_name ? : "",
|
"Can't reapply changes to '%s.%s' setting",
|
||||||
setting_name ? "." : "",
|
setting_name,
|
||||||
first_invalid_key ? : "<UNKNOWN>");
|
first_invalid_key);
|
||||||
|
} else {
|
||||||
|
g_set_error (error,
|
||||||
|
NM_DEVICE_ERROR,
|
||||||
|
NM_DEVICE_ERROR_INCOMPATIBLE_CONNECTION,
|
||||||
|
"Can't reapply any changes to '%s' setting",
|
||||||
|
first_invalid_key);
|
||||||
|
}
|
||||||
g_return_val_if_fail (first_invalid_key, FALSE);
|
g_return_val_if_fail (first_invalid_key, FALSE);
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue