mirror of
https://git.kernel.org/pub/scm/network/wireless/iwd.git
synced 2024-11-16 17:09:24 +01:00
eapol: Fix bogus warning
src/eapol.c:1041:9: error: ‘buf’ may be used uninitialized [-Werror=maybe-uninitialized] 1041 | l_put_be16(0, &frame->header.packet_len); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ This warning is bogus since the buffer is initialized through use of eapol_frame members. EAPoL-Start is a very simple frame.
This commit is contained in:
parent
f81855349a
commit
7604762013
@ -1033,7 +1033,7 @@ static void eapol_install_igtk(struct eapol_sm *sm, uint16_t igtk_key_index,
|
|||||||
|
|
||||||
static void __send_eapol_start(struct eapol_sm *sm, bool noencrypt)
|
static void __send_eapol_start(struct eapol_sm *sm, bool noencrypt)
|
||||||
{
|
{
|
||||||
uint8_t buf[sizeof(struct eapol_frame)];
|
uint8_t buf[sizeof(struct eapol_frame)] = {};
|
||||||
struct eapol_frame *frame = (struct eapol_frame *) buf;
|
struct eapol_frame *frame = (struct eapol_frame *) buf;
|
||||||
|
|
||||||
frame->header.protocol_version = EAPOL_PROTOCOL_VERSION_2001;
|
frame->header.protocol_version = EAPOL_PROTOCOL_VERSION_2001;
|
||||||
|
Loading…
Reference in New Issue
Block a user