1
0
mirror of https://github.com/systemd/systemd.git synced 2024-12-23 21:35:11 +03:00

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:
Yu Watanabe 2019-12-17 20:41:21 +09:00
parent b04c5e51da
commit 4d016e965b

View File

@ -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)