diff options
| author | Vicent Marti <tanoku@gmail.com> | 2011-06-18 01:12:58 +0200 |
|---|---|---|
| committer | Vicent Marti <tanoku@gmail.com> | 2011-06-18 01:12:58 +0200 |
| commit | dbe70bd5c3f803dbcb9fe4880df11cf08093b120 (patch) | |
| tree | 934ee8be383e54cb19e87d73ac66e4e65215d5f7 /tests/t15-config.c | |
| parent | 40070445538ba6ede8dfef36e0a9824f71b33a06 (diff) | |
| download | libgit2-dbe70bd5c3f803dbcb9fe4880df11cf08093b120.tar.gz | |
config: Fix compilation in MSVC
Diffstat (limited to 'tests/t15-config.c')
| -rw-r--r-- | tests/t15-config.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/tests/t15-config.c b/tests/t15-config.c index 78cd9b5d8..5e5b4b14d 100644 --- a/tests/t15-config.c +++ b/tests/t15-config.c @@ -212,18 +212,11 @@ END_TEST BEGIN_TEST(config10, "a repo's config overrides the global config") git_repository *repo; - char home_orig[GIT_PATH_MAX]; - char *home; git_config *cfg; int version; - home = getenv("HOME"); - strcpy(home_orig, home); - setenv("HOME", CONFIG_BASE, 1); - must_pass(git_repository_open(&repo, REPOSITORY_FOLDER)); - must_pass(git_repository_config(&cfg, repo, NULL, NULL)); - setenv("HOME", home_orig, 1); + must_pass(git_repository_config(&cfg, repo, CONFIG_BASE "/.gitconfig", NULL)); must_pass(git_config_get_int(cfg, "core.repositoryformatversion", &version)); must_be_true(version == 0); git_config_free(cfg); |
