Subject: Re: git submodules implementation question

From: Junio C Hamano <[email-masked]>
Date: Wed, 31 Aug 2016 11:44:46 -0700

Uma Srinivasan <[email-masked]> writes:

> diff --git a/submodule.c b/submodule.c
> index 5a62aa2..23443a7 100644
> --- a/submodule.c
> +++ b/submodule.c
> @@ -960,6 +960,9 @@ unsigned is_submodule_modified(const char *path,
> int ignore_untracked)
>                 return 0;
>
>         }
> +       /* stuff submodule git dir into env var */
> +       set_git_dir(git_dir);

We want to affect only the process we are going to spawn to work
inside the submodule, not ourselves, which is what this call does;
this does not sound like a good idea.