From: Ankita Bajaj Date: Mon, 27 Aug 2018 07:31:13 +0000 (+0530) Subject: DPP: Fix a memory leak on Configurator keygen error path X-Git-Tag: hostap_2_7~170 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=820ea0ba934755bad1bdac3bca435312077906c3;p=thirdparty%2Fhostap.git DPP: Fix a memory leak on Configurator keygen error path The allocated configuration structure needs to be freed if the specified curve is not supported. Signed-off-by: Jouni Malinen --- diff --git a/src/common/dpp.c b/src/common/dpp.c index 099219c66..677f58692 100644 --- a/src/common/dpp.c +++ b/src/common/dpp.c @@ -5564,6 +5564,7 @@ dpp_keygen_configurator(const char *curve, const u8 *privkey, if (!conf->curve) { wpa_printf(MSG_INFO, "DPP: Unsupported curve: %s", curve); + os_free(conf); return NULL; } }