radiotap.c: In function ‘ieee80211_radiotap_iterator_init’:
radiotap.c:167:27: warning: taking address of packed member of ‘struct ieee80211_radiotap_header’ may result in an unaligned pointer value [-Waddress-of-packed-member]
167 | iterator->_next_bitmap = &radiotap_header->it_present;
| ^~~~~~~~
this code is included in openwifi its give me above error
radiotap.c: In function ‘ieee80211_radiotap_iterator_init’:
radiotap.c:167:27: warning: taking address of packed member of ‘struct ieee80211_radiotap_header’ may result in an unaligned pointer value [-Waddress-of-packed-member]
167 | iterator->_next_bitmap = &radiotap_header->it_present;
| ^~~~~~~~
That kind of seems both correct and not - if the packet is aligned then the it_present will also aligned, but then we also don't need the packed attribute ...
radiotap.c: In function ‘ieee80211_radiotap_iterator_init’: radiotap.c:167:27: warning: taking address of packed member of ‘struct ieee80211_radiotap_header’ may result in an unaligned pointer value [-Waddress-of-packed-member] 167 | iterator->_next_bitmap = &radiotap_header->it_present; | ^
~~~~~~~radiotap.c:167:27: warning: taking address of packed member of ‘struct ieee80211_radiotap_header’ may result in an unaligned pointer value [-Waddress-of-packed-member] 167 | iterator->_next_bitmap = &radiotap_header->it_present; | ^
~~~~~~~