[Issue] Unable to create group further if failed previously due to incorrect ssid length.
[Solution] Destroy previously created group before returning failure due to incorrect ssid length check.
Change-Id: I60a018ca60fa850cbd7a65b432f55f00d8c73e9e
Name: wifi-direct-manager
Summary: Wi-Fi Direct manger
-Version: 1.3.1
+Version: 1.3.2
Release: 1
Group: Network & Connectivity/Wireless
License: Apache-2.0
ssid_len = strlen(ssid);
if (ssid_len < WIFI_DIRECT_MIN_SSID_LEN || ssid_len > WIFI_DIRECT_MAX_SSID_LEN) {
WDS_LOGE("SSID length incorrect [%s]:[%d], whereas [Proper SSID Length Range is 1-32 ]", ssid, ssid_len);
+ /* Destroy previously created group */
+ wfd_destroy_group(manager);
ret = WIFI_DIRECT_ERROR_INVALID_PARAMETER;
g_variant_iter_free(iter);
return_parameters = g_variant_new("(i)", ret);