From 8957661378b073b49875059d6426614facb0d7f0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20=C3=85gren?= Date: Mon, 7 Aug 2017 20:20:49 +0200 Subject: treewide: deprecate git_config_maybe_bool, use git_parse_maybe_bool MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The only difference between these is that the former takes an argument `name` which it ignores completely. Still, the callers are quite careful to provide reasonable values for it. Once in-flight topics have landed, we should be able to remove git_config_maybe_bool. In the meantime, document it as deprecated in the technical documentation. While at it, document git_parse_maybe_bool. Signed-off-by: Martin Ă…gren Signed-off-by: Junio C Hamano --- submodule-config.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'submodule-config.c') diff --git a/submodule-config.c b/submodule-config.c index 93453909c..0fcdb3926 100644 --- a/submodule-config.c +++ b/submodule-config.c @@ -213,7 +213,7 @@ static struct submodule *lookup_or_create_by_name(struct submodule_cache *cache, static int parse_fetch_recurse(const char *opt, const char *arg, int die_on_error) { - switch (git_config_maybe_bool(opt, arg)) { + switch (git_parse_maybe_bool(arg)) { case 1: return RECURSE_SUBMODULES_ON; case 0: @@ -237,7 +237,7 @@ int parse_fetch_recurse_submodules_arg(const char *opt, const char *arg) static int parse_push_recurse(const char *opt, const char *arg, int die_on_error) { - switch (git_config_maybe_bool(opt, arg)) { + switch (git_parse_maybe_bool(arg)) { case 1: /* There's no simple "on" value when pushing */ if (die_on_error) -- cgit v1.2.1