submodule: use absolute path for computing relative path connecting
commit90c0011619bd4cd4b14c366ab7a9affacb43276a
authorStefan Beller <sbeller@google.com>
Thu, 8 Dec 2016 21:03:24 +0000 (8 13:03 -0800)
committerJunio C Hamano <gitster@pobox.com>
Fri, 9 Dec 2016 22:52:57 +0000 (9 14:52 -0800)
treec24fa10818aba79decba7f6549e8ba628bf79a7a
parent4df1d4d4666eb26b420d5b386010470729846b8c
submodule: use absolute path for computing relative path connecting

The current caller of connect_work_tree_and_git_dir passes
an absolute path for the `git_dir` parameter. In the future patch
we will also pass in relative path for `git_dir`. Extend the functionality
of connect_work_tree_and_git_dir to take relative paths for parameters.

We could work around this in the future patch by computing the absolute
path for the git_dir in the calling site, however accepting relative
paths for either parameter makes the API for this function much harder
to misuse.

Signed-off-by: Stefan Beller <sbeller@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
submodule.c