summaryrefslogtreecommitdiff
path: root/fast-import.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2019-07-09 22:25:38 (GMT)
committerJunio C Hamano <gitster@pobox.com>2019-07-09 22:25:38 (GMT)
commite8d259064146f24abb1280aff0ca3ead20218244 (patch)
tree2a0f4b7ee4f9059928ea9619d14a42ddf4d0c163 /fast-import.c
parentceca45541d0046544cc95acb6b849c14637e0e3e (diff)
parent921d49be86bd44ca290c8db6cc6f419dac3ed442 (diff)
downloadgit-e8d259064146f24abb1280aff0ca3ead20218244.zip
git-e8d259064146f24abb1280aff0ca3ead20218244.tar.gz
git-e8d259064146f24abb1280aff0ca3ead20218244.tar.bz2
Merge branch 'rs/copy-array'
Code clean-up. * rs/copy-array: use COPY_ARRAY for copying arrays coccinelle: use COPY_ARRAY for copying arrays
Diffstat (limited to 'fast-import.c')
-rw-r--r--fast-import.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fast-import.c b/fast-import.c
index 76a7bd3..6dfdd68 100644
--- a/fast-import.c
+++ b/fast-import.c
@@ -644,7 +644,7 @@ static struct tree_content *grow_tree_content(
struct tree_content *r = new_tree_content(t->entry_count + amt);
r->entry_count = t->entry_count;
r->delta_depth = t->delta_depth;
- memcpy(r->entries,t->entries,t->entry_count*sizeof(t->entries[0]));
+ COPY_ARRAY(r->entries, t->entries, t->entry_count);
release_tree_content(t);
return r;
}