diff options
author | Jeff King <peff@peff.net> | 2018-06-29 01:05:09 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-07-03 19:35:12 +0300 |
commit | 63583203df51c645aa2bf2988bbdfa3d308ef517 (patch) | |
tree | 4dc97a476030c3b5e5bb75d167b641f87a0ab255 /config.c | |
parent | 66f9722882993f60be656afaae4c5c9ac92957e9 (diff) |
config: add CONFIG_ERROR_SILENT handler
We can currently die() or error(), but there's not yet any
way for callers to ask us just to quietly return an error.
Let's give them one.
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'config.c')
-rw-r--r-- | config.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -818,6 +818,9 @@ static int git_parse_source(config_fn_t fn, void *data, case CONFIG_ERROR_ERROR: error_return = error("%s", error_msg); break; + case CONFIG_ERROR_SILENT: + error_return = -1; + break; case CONFIG_ERROR_UNSET: BUG("config error action unset"); } |