]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
EAP-SAKE server: Fix memory freeing on error path
authorJouni Malinen <j@w1.fi>
Fri, 19 Apr 2019 13:43:14 +0000 (16:43 +0300)
committerJouni Malinen <j@w1.fi>
Fri, 19 Apr 2019 13:44:38 +0000 (16:44 +0300)
Allocated struct wpabuf was freed with incorrect freeing function. Fix
this by using the appropriate function.

Signed-off-by: Jouni Malinen <j@w1.fi>
src/eap_server/eap_server_sake.c

index 66183f5f5c042fcc42539b51781fd2ba72b2b89a..cda6b2f0f712bdf8d7db3ec80a653c9c2d890083 100644 (file)
@@ -204,7 +204,7 @@ static struct wpabuf * eap_sake_build_confirm(struct eap_sm *sm,
        {
                wpa_printf(MSG_INFO, "EAP-SAKE: Failed to compute MIC");
                data->state = FAILURE;
-               os_free(msg);
+               wpabuf_free(msg);
                return NULL;
        }