diff options
author | Patrick Steinhardt <ps@pks.im> | 2024-08-13 11:13:59 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2024-08-13 19:01:03 +0200 |
commit | 87aace129ef39fc52ca26e8d31c356c8d05ea910 (patch) | |
tree | b058e5e73f83b9fe65773fc2189a10f195163154 /config.c | |
parent | config: pass repo to `git_config_get_max_percent_split_change()` (diff) | |
download | git-87aace129ef39fc52ca26e8d31c356c8d05ea910.tar.xz git-87aace129ef39fc52ca26e8d31c356c8d05ea910.zip |
config: pass repo to `git_config_get_expiry()`
Refactor `git_config_get_expiry()` 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 'config.c')
-rw-r--r-- | config.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -2766,9 +2766,9 @@ int git_config_get_pathname(const char *key, char **dest) return repo_config_get_pathname(the_repository, key, dest); } -int git_config_get_expiry(const char *key, const char **output) +int repo_config_get_expiry(struct repository *r, const char *key, const char **output) { - int ret = git_config_get_string(key, (char **)output); + int ret = repo_config_get_string(r, key, (char **)output); if (ret) return ret; if (strcmp(*output, "now")) { |