config->name = g_key_file_get_string(keyfile, group_name, WIFI_CONFIG_NAME, NULL);
DBG("name [%s]", config->name);
- ret = __get_security_type(config_id, &config->security_type);
- if (ret != TRUE) {
+ __get_security_type(config_id, &config->security_type);
+ if (config->security_type == NULL) {
ERR("Fail to _get_security_type");
g_key_file_free(keyfile);
g_free(group_name);
}
g_key_file_free(keyfile);
+ g_free(group_name);
g_free(conf->name);
g_free(conf->ssid);
g_free(conf->passphrase);
}
g_key_file_free(keyfile);
+ g_free(group_name);
__free_wifi_configuration(conf);
g_variant_iter_free(iter);