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/t/helper
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2022-09-14 22:56:39 +0300
committerJunio C Hamano <gitster@pobox.com>2022-09-14 22:56:39 +0300
commitdd407f1c7c7cce148d7313537494d0bc049ccb0e (patch)
tree960438c348acf300fca1f9e795b647df2d6f8e18 /t/helper
parenta6b42ec0c6e2ef492b0ed6d1f1123dc7e724154e (diff)
parent9ff7eb8c8882c477919acfe28a3d68bb58adf2ea (diff)
Merge branch 'ab/unused-annotation'
Undoes 'jk/unused-annotation' topic and redoes it to work around Coccinelle rules misfiring false positives in unrelated codepaths. * ab/unused-annotation: git-compat-util.h: use "deprecated" for UNUSED variables git-compat-util.h: use "UNUSED", not "UNUSED(var)"
Diffstat (limited to 't/helper')
-rw-r--r--t/helper/test-config.c2
-rw-r--r--t/helper/test-ref-store.c4
-rw-r--r--t/helper/test-userdiff.c2
3 files changed, 4 insertions, 4 deletions
diff --git a/t/helper/test-config.c b/t/helper/test-config.c
index ddd538b838..4ba9eb6560 100644
--- a/t/helper/test-config.c
+++ b/t/helper/test-config.c
@@ -37,7 +37,7 @@
*
*/
-static int iterate_cb(const char *var, const char *value, void *UNUSED(data))
+static int iterate_cb(const char *var, const char *value, void *data UNUSED)
{
static int nr;
diff --git a/t/helper/test-ref-store.c b/t/helper/test-ref-store.c
index 8f930ad358..ae8a5648da 100644
--- a/t/helper/test-ref-store.c
+++ b/t/helper/test-ref-store.c
@@ -161,7 +161,7 @@ static int cmd_rename_ref(struct ref_store *refs, const char **argv)
}
static int each_ref(const char *refname, const struct object_id *oid,
- int flags, void *UNUSED(cb_data))
+ int flags, void *cb_data UNUSED)
{
printf("%s %s 0x%x\n", oid_to_hex(oid), refname, flags);
return 0;
@@ -207,7 +207,7 @@ static int cmd_for_each_reflog(struct ref_store *refs, const char **argv)
static int each_reflog(struct object_id *old_oid, struct object_id *new_oid,
const char *committer, timestamp_t timestamp,
- int tz, const char *msg, void *UNUSED(cb_data))
+ int tz, const char *msg, void *cb_data UNUSED)
{
printf("%s %s %s %" PRItime " %+05d%s%s", oid_to_hex(old_oid),
oid_to_hex(new_oid), committer, timestamp, tz,
diff --git a/t/helper/test-userdiff.c b/t/helper/test-userdiff.c
index 64538a0c20..a2b56b9cae 100644
--- a/t/helper/test-userdiff.c
+++ b/t/helper/test-userdiff.c
@@ -12,7 +12,7 @@ static int driver_cb(struct userdiff_driver *driver,
return 0;
}
-static int cmd__userdiff_config(const char *var, const char *value, void *UNUSED(cb))
+static int cmd__userdiff_config(const char *var, const char *value, void *cb UNUSED)
{
if (userdiff_config(var, value) < 0)
return -1;