Code

submodule: fix relative url parsing for scp-style origin
[git.git] / connect.c
index a37cf6af0428023d2d3ef01ab2e04fc462981af4..beaff987c7bc36096d09b2557f5208c5606ce2dd 100644 (file)
--- a/connect.c
+++ b/connect.c
@@ -607,18 +607,8 @@ struct child_process *git_connect(int fd[2], const char *url_orig,
                *arg++ = host;
        }
        else {
-               /* remove these from the environment */
-               const char *env[] = {
-                       ALTERNATE_DB_ENVIRONMENT,
-                       DB_ENVIRONMENT,
-                       GIT_DIR_ENVIRONMENT,
-                       GIT_WORK_TREE_ENVIRONMENT,
-                       GRAFT_ENVIRONMENT,
-                       INDEX_ENVIRONMENT,
-                       NO_REPLACE_OBJECTS_ENVIRONMENT,
-                       NULL
-               };
-               conn->env = env;
+               /* remove repo-local variables from the environment */
+               conn->env = local_repo_env;
                conn->use_shell = 1;
        }
        *arg++ = cmd.buf;