convert.c: guard config parser from value=NULL
filter.*.smudge and filter.*.clean configuration variables expect a string value. Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
c64b9ad0fc
commit
a7269e5cb7
@ -326,14 +326,14 @@ static int read_convert_config(const char *var, const char *value)
|
||||
|
||||
if (!strcmp("smudge", ep)) {
|
||||
if (!value)
|
||||
return error("%s: lacks value", var);
|
||||
return config_error_nonbool(var);
|
||||
drv->smudge = strdup(value);
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (!strcmp("clean", ep)) {
|
||||
if (!value)
|
||||
return error("%s: lacks value", var);
|
||||
return config_error_nonbool(var);
|
||||
drv->clean = strdup(value);
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user