diff options
Diffstat (limited to 'commit-reach.c')
| -rw-r--r-- | commit-reach.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/commit-reach.c b/commit-reach.c index c226ee3da4..5ba822a720 100644 --- a/commit-reach.c +++ b/commit-reach.c @@ -1,7 +1,9 @@ -#include "cache.h" +#include "git-compat-util.h" +#include "alloc.h" #include "commit.h" #include "commit-graph.h" #include "decorate.h" +#include "hex.h" #include "prio-queue.h" #include "tree.h" #include "ref-filter.h" @@ -245,8 +247,7 @@ static int remove_redundant_with_gen(struct repository *r, * min_gen_pos points to the current position within 'array' * that is not yet known to be STALE. */ - ALLOC_ARRAY(sorted, cnt); - COPY_ARRAY(sorted, array, cnt); + DUP_ARRAY(sorted, array, cnt); QSORT(sorted, cnt, compare_commits_by_gen); min_generation = commit_graph_generation(sorted[0]); |
