Hi,

Don't you like to use __attribute__((unused)) for marking a parameter when such a need comes up?

04.08.2024 06:18, Kian Kasad пишет:
This fixes an error which was introduced by
2f50b47c72cbc4270bbd12ae7f520486d5f42736. Git added a new argument to
config_fn_t, and it was added to gitconfig_config(), but not named. This
causes compile warnings/errors. This commit fixes that by naming the new
parameter.
---
  scan-tree.c | 3 ++-
  1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/scan-tree.c b/scan-tree.c
index 84da86e..d4fecd8 100644
--- a/scan-tree.c
+++ b/scan-tree.c
@@ -54,7 +54,8 @@ static void scan_tree_repo_config(const char *name, const 
char *value)
        config_fn(repo, name, value);
  }
-static int gitconfig_config(const char *key, const char *value, const struct config_context *, void *cb)
+static int gitconfig_config(const char *key, const char *value,
+               const struct config_context *UNUSED, void *cb)
  {
        const char *name;

Reply via email to