Change-Id: I65108912c5672e74c5e913d88052ce3fe0a8d817
Signed-off-by: DoHyun Pyun <dh79.pyun@samsung.com>
char_info->char_value = g_try_realloc(char_info->char_value, value_length);
}
if (char_info->char_value) {
- if (str) {
+ if (str)
memcpy(char_info->char_value, str, strlen(str));
- g_free(str);
- }
+
if (offset > 0) {
memcpy(&char_info->char_value[offset], value, value_length);
char_info->value_length = offset + value_length;
hps_char_list = g_slist_insert_sorted(hps_char_list,
char_info, char_info_cmp);
}
+ g_free(str);
return;
}
}