Merge branch 'jh/maint-submodule-status-in-void' (early part)
[gitweb.git] / setup.c
diff --git a/setup.c b/setup.c
index fac34f77a7800193e636f49c799908f629540de1..0717a98d16b8be3cb70b33b6dea7040694130a0b 100644 (file)
--- a/setup.c
+++ b/setup.c
@@ -404,9 +404,9 @@ const char *setup_git_directory_gently(int *nongit_ok)
                                inside_work_tree = 0;
                        if (offset != len) {
                                cwd[offset] = '\0';
-                               setenv(GIT_DIR_ENVIRONMENT, cwd, 1);
+                               set_git_dir(cwd);
                        } else
-                               setenv(GIT_DIR_ENVIRONMENT, ".", 1);
+                               set_git_dir(".");
                        check_repository_format_gently(nongit_ok);
                        return NULL;
                }