From b337172c834b854903fb523416b53fe354b6e2a5 Mon Sep 17 00:00:00 2001 From: Brandon Williams Date: Thu, 22 Jun 2017 11:43:37 -0700 Subject: path: convert strbuf_git_common_path to take a 'struct repository' Signed-off-by: Brandon Williams Signed-off-by: Junio C Hamano --- worktree.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'worktree.c') diff --git a/worktree.c b/worktree.c index 2801c6d52b..e28ffbeb09 100644 --- a/worktree.c +++ b/worktree.c @@ -1,4 +1,5 @@ #include "cache.h" +#include "repository.h" #include "refs.h" #include "strbuf.h" #include "worktree.h" @@ -76,7 +77,7 @@ static struct worktree *get_linked_worktree(const char *id) if (!id) die("Missing linked worktree name"); - strbuf_git_common_path(&path, "worktrees/%s/gitdir", id); + strbuf_git_common_path(&path, the_repository, "worktrees/%s/gitdir", id); if (strbuf_read_file(&worktree_path, path.buf, 0) <= 0) /* invalid gitdir file */ goto done; -- cgit v1.2.3