From: Junio C Hamano Date: Mon, 11 Feb 2008 18:48:12 +0000 (-0800) Subject: builtin-config.c: guard config parser from value=NULL X-Git-Tag: v1.5.4.2~45 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=f769982d02f70534789593e2bab889c9aa3a641c;p=git.git builtin-config.c: guard config parser from value=NULL color configuration variables expect a string value. Signed-off-by: Junio C Hamano --- diff --git a/builtin-config.c b/builtin-config.c index e4a12e316..077d8ef2d 100644 --- a/builtin-config.c +++ b/builtin-config.c @@ -168,6 +168,8 @@ static char parsed_color[COLOR_MAXLEN]; static int git_get_color_config(const char *var, const char *value) { if (!strcmp(var, get_color_slot)) { + if (!value) + config_error_nonbool(var); color_parse(value, var, parsed_color); get_color_found = 1; }