wifi_get_connected_ap() returns ap handle with allocated memory which
needs to be destroyed after use.
Change-Id: Ic157ddd973504b0a20ae87d2286fab5bc42de3f4
Signed-off-by: Saurav Babu <saurav.babu@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/5409
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Madan Lanka <lanka.madan@samsung.com>
if(WIFI_ERROR_NONE != ret)
{
ERR("wifi_ap_get_ip_address() Fail");
+ wifi_ap_destroy(ap);
return NULL;
}
+ wifi_ap_destroy(ap);
return ip_addr;
}