Re: [PATCH 07/11] files-backend: remove the use of git_path()
- From
Stefan Beller <sbeller@google.com>
- Date
- Feb 13, 2017, 23:09 UTC
- Message-ID
- <CAGZ79kbJXUY=UGvHtkeLLj-qMaoOyTwa2dr3-FqEdYi8eFs4LA@mail.gmail.com>
- In-Reply-To
- <20170213152011.12050-8-pclouds@gmail.com>
> +
> + if (submodule) {
> + refs->submodule = xstrdup_or_null(submodule);drop the _or_null here?
So in this patch we have either * submodule set * or gitdir/gitcommondir set
which means that we exercise the commondir for regular repos. In the future when we want to be able to have a combination of worktrees and submodules this ought to be possible by setting submodule != NULL and still populating the gitdir/commondir buffers.
Thanks, Stefan