diff options
author | Jeff King <peff@peff.net> | 2015-01-20 23:14:48 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2015-01-21 00:56:03 +0100 |
commit | 3759d27aca3ddd78b4b1169a767809748dc1fc3f (patch) | |
tree | 731e77e963a86dec0dced2086c7e0c1439b827f5 /color.c | |
parent | parse_color: drop COLOR_BACKGROUND macro (diff) | |
download | git-3759d27aca3ddd78b4b1169a767809748dc1fc3f.tar.xz git-3759d27aca3ddd78b4b1169a767809748dc1fc3f.zip |
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 <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'color.c')
-rw-r--r-- | color.c | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -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; |