mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-01-06 13:17:44 +03:00
networkctl: read permanent hardware address from netlink message
This commit is contained in:
parent
8a77e245df
commit
49c351a8ac
@ -557,7 +557,8 @@ static int decode_link(sd_netlink_message *m, LinkInfo *info, char **patterns, b
|
||||
info->hw_address.length > 0;
|
||||
|
||||
info->has_permanent_hw_address =
|
||||
ethtool_get_permanent_hw_addr(NULL, info->name, &info->permanent_hw_address) >= 0 &&
|
||||
(netlink_message_read_hw_addr(m, IFLA_PERM_ADDRESS, &info->permanent_hw_address) >= 0 ||
|
||||
ethtool_get_permanent_hw_addr(NULL, info->name, &info->permanent_hw_address) >= 0) &&
|
||||
!hw_addr_is_null(&info->permanent_hw_address) &&
|
||||
!hw_addr_equal(&info->permanent_hw_address, &info->hw_address);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user