From 58e2ba0535359e2c0173215a1dc2f1d574061c56 Mon Sep 17 00:00:00 2001 From: Thomas Haller Date: Wed, 8 Mar 2023 16:22:05 +0100 Subject: [PATCH] glib-aux: drop ethernet fields from NMIPAddr union It's not really used anyway. The idea was, that the ethernet MAC address would fit from the size, and we might at a few places use that for convenience. But it's more confusing. Also, because there is already NMEtherAddr and `struct ether_addr`. --- src/libnm-glib-aux/nm-inet-utils.h | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/src/libnm-glib-aux/nm-inet-utils.h b/src/libnm-glib-aux/nm-inet-utils.h index 8421929e52..5540f3efd0 100644 --- a/src/libnm-glib-aux/nm-inet-utils.h +++ b/src/libnm-glib-aux/nm-inet-utils.h @@ -9,14 +9,7 @@ typedef struct _NMIPAddr { in_addr_t addr4; struct in_addr addr4_struct; struct in6_addr addr6; - - /* NMIPAddr is really a union for IP addresses. - * However, as ethernet addresses fit in here nicely, use - * it also for an ethernet MAC address. */ - guint8 ether_addr_octet[6 /*ETH_ALEN*/]; - NMEtherAddr ether_addr; - - guint8 array[sizeof(struct in6_addr)]; + guint8 array[sizeof(struct in6_addr)]; }; } NMIPAddr;