all: remove use of struct ether_addr / ether_aton()
Lots of old code used struct ether_addr to store hardware addresses, and ether_aton() to parse them, but more recent code generally uses guint8 arrays, and the nm_utils_hwaddr_* methods, to be able to share code between ETH_ALEN and INFINIBAND_ALEN cases. So update the old code to match the new. (In many places, this ends up getting rid of casts between struct ether_addr and guint8* anyway.) (Also, in some places, variables were switched from struct ether_addr to guint8[] a while back, but some code still used "&" when referring to them even though that's unnecessary now. Clean that up.)
This commit is contained in:
@@ -120,12 +120,12 @@ wifi_utils_get_ssid (WifiData *data)
|
||||
}
|
||||
|
||||
gboolean
|
||||
wifi_utils_get_bssid (WifiData *data, struct ether_addr *out_bssid)
|
||||
wifi_utils_get_bssid (WifiData *data, guint8 *out_bssid)
|
||||
{
|
||||
g_return_val_if_fail (data != NULL, FALSE);
|
||||
g_return_val_if_fail (out_bssid != NULL, FALSE);
|
||||
|
||||
memset (out_bssid, 0, sizeof (*out_bssid));
|
||||
memset (out_bssid, 0, ETH_ALEN);
|
||||
return data->get_bssid (data, out_bssid);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user