diff options
Diffstat (limited to 'repository.c')
-rw-r--r-- | repository.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/repository.c b/repository.c index 5cad2dcc86..682c239fe3 100644 --- a/repository.c +++ b/repository.c @@ -157,7 +157,7 @@ int repo_init(struct repository *repo, const char *gitdir, const char *worktree) { - struct repository_format format; + struct repository_format format = REPOSITORY_FORMAT_INIT; memset(repo, 0, sizeof(*repo)); repo->objects = raw_object_store_new(); @@ -174,6 +174,7 @@ int repo_init(struct repository *repo, if (worktree) repo_set_worktree(repo, worktree); + clear_repository_format(&format); return 0; error: |