char *value = NULL;
GVariantIter *iter = NULL;
g_variant_get(val, "as", &iter);
+
+ ret_if(iter == NULL);
+
while (g_variant_iter_loop(iter, "s", &name)) {
BT_DBG("name = %s", name);
g_variant_iter_loop(iter, "s", &value);
if (FALSE == _bt_update_le_feature_support(name, value))
BT_INFO("Fail to update LE feature info");
}
- if (iter)
- g_variant_iter_free(iter);
+
+ g_variant_iter_free(iter);
} else if (strcasecmp(property, "IpspInitStateChanged") == 0) {
gboolean ipsp_initialized = FALSE;
&le_dev_info->rssi,
&le_dev_info->adv_data_len,
&value);
+
+ ret_if(value == NULL);
+
_bt_convert_device_path_to_address(path, le_dev_info->address);
buffer_len = g_variant_get_size(value);