Change to check destination path's size of strncpy
Change-Id: Iad8a0f0fb7ca7777e663cb2f058975473fd0ee2e
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
if (!(file_info->d_type & DT_DIR)) {
snprintf(rel_path_old_tpk_file, PATH_MAX, "%s/%s", dir_name, d_name);
strncpy(path, rel_path_old_tpk_file + strlen(tpk_path),
- strlen(rel_path_old_tpk_file));
+ sizeof(path) - 1);
file_path = strndup(path, sizeof(path));
list = g_list_append(list, file_path);
memset(path, 0, PATH_MAX);