summaryrefslogtreecommitdiff
path: root/color.c
diff options
context:
space:
mode:
Diffstat (limited to 'color.c')
-rw-r--r--color.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/color.c b/color.c
index 62977f4808..8f07fc9547 100644
--- a/color.c
+++ b/color.c
@@ -138,6 +138,9 @@ int git_config_colorbool(const char *var, const char *value, int stdout_is_tty)
goto auto_color;
}
+ if (!var)
+ return -1;
+
/* Missing or explicit false to turn off colorization */
if (!git_config_bool(var, value))
return 0;