projects
/
git.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5768c98
)
builtin-commit.c: guard config parser from value=NULL
author
Junio C Hamano
<gitster@pobox.com>
Mon, 11 Feb 2008 18:46:39 +0000
(10:46 -0800)
committer
Junio C Hamano
<gitster@pobox.com>
Mon, 11 Feb 2008 21:11:36 +0000
(13:11 -0800)
commit.template configuration expects a string value.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin-commit.c
patch
|
blob
|
history
diff --git
a/builtin-commit.c
b/builtin-commit.c
index 3a47275b8c71ba83ea68107d2430efbf58f24c6e..a43f2019959a950639f013ff534610e228d8c149 100644
(file)
--- 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;
}