diff options
| author | Patrick Steinhardt <ps@pks.im> | 2024-08-13 11:14:07 +0200 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2024-08-13 10:01:04 -0700 |
| commit | 0c2c37d16b170697e7c97be5db7dca58b877c4e5 (patch) | |
| tree | 52d277d4e6ebde1843290d059251183d01d1c1d6 /builtin | |
| parent | 44ebcd6254ce9e42eeaa70b67750efb356157914 (diff) | |
| download | git-0c2c37d16b170697e7c97be5db7dca58b877c4e5.tar.gz | |
config: pass repo to `git_die_config()`
Refactor `git_die_config()` to accept a `struct repository` such that we
can get rid of the implicit dependency on `the_repository`. Rename the
function accordingly.
Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin')
| -rw-r--r-- | builtin/fast-import.c | 4 | ||||
| -rw-r--r-- | builtin/notes.c | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/builtin/fast-import.c b/builtin/fast-import.c index d21c4053a7..0249503c70 100644 --- a/builtin/fast-import.c +++ b/builtin/fast-import.c @@ -3481,8 +3481,8 @@ static void git_pack_config(void) if (!git_config_get_int("pack.indexversion", &indexversion_value)) { pack_idx_opts.version = indexversion_value; if (pack_idx_opts.version > 2) - git_die_config("pack.indexversion", - "bad pack.indexVersion=%"PRIu32, pack_idx_opts.version); + git_die_config(the_repository, "pack.indexversion", + "bad pack.indexVersion=%"PRIu32, pack_idx_opts.version); } if (!git_config_get_ulong("pack.packsizelimit", &packsizelimit_value)) max_packsize = packsizelimit_value; diff --git a/builtin/notes.c b/builtin/notes.c index d9c356e354..c0fa86d847 100644 --- a/builtin/notes.c +++ b/builtin/notes.c @@ -868,7 +868,7 @@ static int git_config_get_notes_strategy(const char *key, if (git_config_get_string(key, &value)) return 1; if (parse_notes_merge_strategy(value, strategy)) - git_die_config(key, _("unknown notes merge strategy %s"), value); + git_die_config(the_repository, key, _("unknown notes merge strategy %s"), value); free(value); return 0; |
