From 023ba1ea329631ec4dbec25391e25275ca28278c Mon Sep 17 00:00:00 2001 From: Denis Kenzior Date: Thu, 31 Aug 2017 18:23:47 -0500 Subject: [PATCH] mpdu: Fix error MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit src/mpdu.c: In function ‘mpdu_validate’: src/mpdu.c:180:9: error: ‘mmpdu’ may be used uninitialized in this function [-Werror=maybe-uninitialized] mmpdu = (const struct mmpdu_header *) mmpdu; ^ --- src/mpdu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mpdu.c b/src/mpdu.c index cdac4477..6abf2ac9 100644 --- a/src/mpdu.c +++ b/src/mpdu.c @@ -177,7 +177,7 @@ const struct mmpdu_header *mpdu_validate(const uint8_t *frame, int len) switch (fc->type) { case MPDU_TYPE_MANAGEMENT: - mmpdu = (const struct mmpdu_header *) mmpdu; + mmpdu = (const struct mmpdu_header *) frame; if (validate_mgmt_mpdu(mmpdu, len, &offset)) return mmpdu;