summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRussell Belfer <rb@github.com>2012-08-29 11:01:46 -0700
committerRussell Belfer <rb@github.com>2012-08-29 11:01:46 -0700
commit04d4fe5ef009e9ee2ea98f5f95c798311aec9353 (patch)
treeb9ab5294270cbda955a82c9afb774abbb7efbf3a /src
parent319ad0ba208ec67523a808269b8662c88727a0c9 (diff)
parent89cd5708d94d8eb68a5e3a7b0fbda6ee904fb148 (diff)
downloadlibgit2-04d4fe5ef009e9ee2ea98f5f95c798311aec9353.tar.gz
Merge pull request #908 from nulltoken/bug/repo_reinit_init
repository: add failing repo initialization test
Diffstat (limited to 'src')
-rw-r--r--src/repository.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/repository.c b/src/repository.c
index c12df25c3..b9d180da4 100644
--- a/src/repository.c
+++ b/src/repository.c
@@ -777,8 +777,8 @@ static int repo_init_config(
SET_REPO_CONFIG(string, "core.worktree", work_dir);
}
else if ((opts->flags & GIT_REPOSITORY_INIT__IS_REINIT) != 0) {
- if ((error = git_config_delete(config, "core.worktree")) < 0)
- goto cleanup;
+ if (git_config_delete(config, "core.worktree") < 0)
+ giterr_clear();
}
} else {
if (!are_symlinks_supported(repo_dir))