Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/attr.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2023-01-22 04:21:58 +0300
committerJunio C Hamano <gitster@pobox.com>2023-01-22 04:21:58 +0300
commit60ce816cb637f8fac5e8e5b8a53dff8707b2c04c (patch)
tree54c95811c38748e928c7e788812844d85e8a059d /attr.c
parent90c47b3fbabd6ffecfd234911841892b562cfe9e (diff)
parent6e578410960d9ceb35ec98ad4b6fc711f1a9c85c (diff)
Merge branch 'rs/dup-array'
Code cleaning. * rs/dup-array: use DUP_ARRAY add DUP_ARRAY do full type check in BARF_UNLESS_COPYABLE factor out BARF_UNLESS_COPYABLE mingw: make argv2 in try_shell_exec() non-const
Diffstat (limited to 'attr.c')
-rw-r--r--attr.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/attr.c b/attr.c
index 9922529b58..7783b87d8a 100644
--- a/attr.c
+++ b/attr.c
@@ -603,8 +603,7 @@ struct attr_check *attr_check_dup(const struct attr_check *check)
ret->nr = check->nr;
ret->alloc = check->alloc;
- ALLOC_ARRAY(ret->items, ret->nr);
- COPY_ARRAY(ret->items, check->items, ret->nr);
+ DUP_ARRAY(ret->items, check->items, ret->nr);
return ret;
}