From 3759d27aca3ddd78b4b1169a767809748dc1fc3f Mon Sep 17 00:00:00 2001 From: Jeff King Date: Tue, 20 Jan 2015 17:14:48 -0500 Subject: parse_color: fix return value for numeric color values 0-8 When commit 695d95d refactored the color parsing, it missed a "return 0" when parsing literal numbers 0-8 (which represent basic ANSI colors), leading us to report these colors as an error. Signed-off-by: Jeff King Signed-off-by: Junio C Hamano --- color.c | 1 + 1 file changed, 1 insertion(+) (limited to 'color.c') diff --git a/color.c b/color.c index 809b359a42..9027352ad7 100644 --- a/color.c +++ b/color.c @@ -112,6 +112,7 @@ static int parse_color(struct color *out, const char *name, int len) } else if (val < 8) { out->type = COLOR_ANSI; out->value = val; + return 0; } else if (val < 256) { out->type = COLOR_256; out->value = val; -- cgit v1.2.3