diff options
Diffstat (limited to 'repository.c')
-rw-r--r-- | repository.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/repository.c b/repository.c index cf440405a8..686a964ad6 100644 --- a/repository.c +++ b/repository.c @@ -1,5 +1,6 @@ #include "cache.h" #include "repository.h" +#include "config.h" /* The main repository */ static struct repository the_repo; @@ -156,4 +157,10 @@ void repo_clear(struct repository *repo) repo->index_file = NULL; free(repo->worktree); repo->worktree = NULL; + + if (repo->config) { + git_configset_clear(repo->config); + free(repo->config); + repo->config = NULL; + } } |