Merge branch 'rs/strbuf-add-real-path'
An helper function to make it easier to append the result from real_path() to a strbuf has been added. * rs/strbuf-add-real-path: strbuf: add strbuf_add_real_path() cocci: use ALLOC_ARRAY
This commit is contained in:
@ -175,7 +175,7 @@ struct worktree **get_worktrees(unsigned flags)
|
||||
struct dirent *d;
|
||||
int counter = 0, alloc = 2;
|
||||
|
||||
list = xmalloc(alloc * sizeof(struct worktree *));
|
||||
ALLOC_ARRAY(list, alloc);
|
||||
|
||||
list[counter++] = get_main_worktree();
|
||||
|
||||
|
Reference in New Issue
Block a user