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
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2022-09-13 22:21:09 +0300
committerJunio C Hamano <gitster@pobox.com>2022-09-13 22:21:09 +0300
commitc61614e30f6df550a5d48fc115fb6a92266ecf50 (patch)
tree656c0d10c1a45b3e62a77b813dee3f9a0eca0848 /promisor-remote.c
parentaa31cb89743a9ba4efd43f5160bfea0a4cbe5858 (diff)
parentc4bbd9bb8fd307c3c8be16121391416a5685ffe1 (diff)
Merge branch 'sg/xcalloc-cocci-fix' into maint
xcalloc(), imitating calloc(), takes "number of elements of the array", and "size of a single element", in this order. A call that does not follow this ordering has been corrected. * sg/xcalloc-cocci-fix: promisor-remote: fix xcalloc() argument order
Diffstat (limited to 'promisor-remote.c')
-rw-r--r--promisor-remote.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/promisor-remote.c b/promisor-remote.c
index 5b33f88bca..68f46f5ec7 100644
--- a/promisor-remote.c
+++ b/promisor-remote.c
@@ -146,7 +146,7 @@ static void promisor_remote_init(struct repository *r)
if (r->promisor_remote_config)
return;
config = r->promisor_remote_config =
- xcalloc(sizeof(*r->promisor_remote_config), 1);
+ xcalloc(1, sizeof(*r->promisor_remote_config));
config->promisors_tail = &config->promisors;
repo_config(r, promisor_remote_config, config);