summaryrefslogtreecommitdiff
path: root/builtin/pack-objects.c
diff options
context:
space:
mode:
Diffstat (limited to 'builtin/pack-objects.c')
-rw-r--r--builtin/pack-objects.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/builtin/pack-objects.c b/builtin/pack-objects.c
index b59f5d895e..d39193453a 100644
--- a/builtin/pack-objects.c
+++ b/builtin/pack-objects.c
@@ -89,8 +89,7 @@ static void index_commit_for_bitmap(struct commit *commit)
{
if (indexed_commits_nr >= indexed_commits_alloc) {
indexed_commits_alloc = (indexed_commits_alloc + 32) * 2;
- indexed_commits = xrealloc(indexed_commits,
- indexed_commits_alloc * sizeof(struct commit *));
+ REALLOC_ARRAY(indexed_commits, indexed_commits_alloc);
}
indexed_commits[indexed_commits_nr++] = commit;