diff options
| author | Junio C Hamano <gitster@pobox.com> | 2023-12-20 10:14:54 -0800 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2023-12-20 10:14:54 -0800 |
| commit | 2b9cbc6d01ba3e54de09efde1dd2ed46c2d36e94 (patch) | |
| tree | 6ccb23924e2b2d806b3d67cf3796d3d7ad4695a2 /notes-utils.c | |
| parent | Merge branch 'jk/bisect-reset-fix' (diff) | |
| parent | fsck: handle NULL value when parsing message config (diff) | |
| download | git-2b9cbc6d01ba3e54de09efde1dd2ed46c2d36e94.tar.gz git-2b9cbc6d01ba3e54de09efde1dd2ed46c2d36e94.zip | |
Merge branch 'jk/implicit-true'
Some codepaths did not correctly parse configuration variables
specified with valueless "true", which has been corrected.
* jk/implicit-true:
fsck: handle NULL value when parsing message config
trailer: handle NULL value when parsing trailer-specific config
submodule: handle NULL value when parsing submodule.*.branch
help: handle NULL value for alias.* config
trace2: handle NULL values in tr2_sysenv config callback
setup: handle NULL value when parsing extensions
config: handle NULL value when parsing non-bools
Diffstat (limited to 'notes-utils.c')
| -rw-r--r-- | notes-utils.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/notes-utils.c b/notes-utils.c index 97c031c26e..01f4f5b424 100644 --- a/notes-utils.c +++ b/notes-utils.c @@ -112,6 +112,8 @@ static int notes_rewrite_config(const char *k, const char *v, } return 0; } else if (!c->refs_from_env && !strcmp(k, "notes.rewriteref")) { + if (!v) + return config_error_nonbool(k); /* note that a refs/ prefix is implied in the * underlying for_each_glob_ref */ if (starts_with(v, "refs/notes/")) |
