diff options
author | Junio C Hamano <gitster@pobox.com> | 2017-11-15 12:05:01 +0900 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-11-15 12:05:01 +0900 |
commit | 16f8cd1fba98fc39ac32c7063e38f9c8470f643a (patch) | |
tree | a22490ffa5dff485e87b366a60e77eb0cbeea13b | |
parent | 934e330c9d0d12f7a0dd82b9699456c891e4dd4a (diff) | |
parent | fa4d8c783d780191d98fe1f68ad2dea2fe78d19c (diff) | |
download | git-16f8cd1fba98fc39ac32c7063e38f9c8470f643a.tar.gz git-16f8cd1fba98fc39ac32c7063e38f9c8470f643a.tar.xz |
Merge branch 'js/early-config' into maint
Correct start-up sequence so that a repository could be placed
immediately under the root directory again (which was broken at
around Git 2.13).
* js/early-config:
setup: avoid double slashes when looking for HEAD
-rw-r--r-- | setup.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -312,7 +312,9 @@ int is_git_directory(const char *suspect) size_t len; /* Check worktree-related signatures */ - strbuf_addf(&path, "%s/HEAD", suspect); + strbuf_addstr(&path, suspect); + strbuf_complete(&path, '/'); + strbuf_addstr(&path, "HEAD"); if (validate_headref(path.buf)) goto done; |