udev: sort alternative names
Kernel preserves the order of alternative names. So, for user visibility, let's sort the alternative names.
This commit is contained in:
parent
b04c5e51da
commit
4d016e965b
|
@ -503,6 +503,7 @@ int link_config_apply(link_config_ctx *ctx, link_config *config,
|
|||
strv_remove(altnames, new_name);
|
||||
strv_remove(altnames, old_name);
|
||||
strv_uniq(altnames);
|
||||
strv_sort(altnames);
|
||||
|
||||
r = rtnl_set_link_alternative_names(&ctx->rtnl, ifindex, altnames);
|
||||
if (r == -EOPNOTSUPP)
|
||||
|
|
Loading…
Reference in a new issue