summaryrefslogtreecommitdiff
path: root/src/network/networkctl.c
diff options
context:
space:
mode:
authorYu Watanabe <watanabe.yu+github@gmail.com>2021-11-06 14:12:30 +0900
committerYu Watanabe <watanabe.yu+github@gmail.com>2021-11-09 08:20:51 +0900
commitde0f1579847a69f51db4e00062eafc37df7456fe (patch)
tree6fd24d241e1c3a0ecf2776b3319aa009e4c22a45 /src/network/networkctl.c
parent1f86a3fe52c71af7f46381bf45c2efe580a19dcc (diff)
downloadsystemd-de0f1579847a69f51db4e00062eafc37df7456fe.tar.gz
ether-addr-util: make hw_addr_is_null() return true also for all zero address
This fixes the following error: --- systemd-networkd[1449490]: ip6tnl0: Saved hardware address: 00:00:00:00:00:00:00:00:00:00:00:00:00:00:00:00 systemd-networkd[1449490]: ip6tnl0: Failed to manage link by its new hardware address, ignoring: File exists ---
Diffstat (limited to 'src/network/networkctl.c')
-rw-r--r--src/network/networkctl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/network/networkctl.c b/src/network/networkctl.c
index 6dd05145c9..bb6e0f6b5b 100644
--- a/src/network/networkctl.c
+++ b/src/network/networkctl.c
@@ -553,7 +553,7 @@ static int decode_link(sd_netlink_message *m, LinkInfo *info, char **patterns, b
info->has_mac_address =
netlink_message_read_hw_addr(m, IFLA_ADDRESS, &info->hw_address) >= 0 &&
- !hw_addr_is_null(&info->hw_address);
+ info->hw_address.length > 0;
info->has_permanent_mac_address =
ethtool_get_permanent_macaddr(NULL, info->name, &info->permanent_mac_address) >= 0 &&