(list->nr - index)
* sizeof(struct path_list_item));
list->items[index].path = list->strdup_paths ?
- strdup(path) : (char *)path;
+ xstrdup(path) : (char *)path;
list->items[index].util = NULL;
list->nr++;
for (i = 0; i < list->nr; i++) {
if (list->strdup_paths)
free(list->items[i].path);
- if (list->items[i].util)
- free(list->items[i].util);
+ free(list->items[i].util);
}
free(list->items);
}