From: Junio C Hamano Date: Mon, 11 Feb 2008 18:46:39 +0000 (-0800) Subject: builtin-commit.c: guard config parser from value=NULL X-Git-Tag: v1.5.4.2~46 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=d865eb2a0d5f121a46dfcc18c78e7f27e0af0fbc;p=git.git builtin-commit.c: guard config parser from value=NULL commit.template configuration expects a string value. Signed-off-by: Junio C Hamano --- diff --git a/builtin-commit.c b/builtin-commit.c index 3a47275b8..a43f20199 100644 --- a/builtin-commit.c +++ b/builtin-commit.c @@ -743,6 +743,8 @@ static void print_summary(const char *prefix, const unsigned char *sha1) int git_commit_config(const char *k, const char *v) { if (!strcmp(k, "commit.template")) { + if (!v) + return config_error_nonbool(v); template_file = xstrdup(v); return 0; }