Skip to content

Commit b6b24fc

Browse files
stefanbellergitster
authored andcommitted
path.h: make REPO_GIT_PATH_FUNC repository agnostic
git_pathdup uses the_repository internally, but the macro REPO_GIT_PATH_FUNC is specifically made for arbitrary repositories. Switch to repo_git_path which works on arbitrary repositories. Signed-off-by: Stefan Beller <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 6a7895f commit b6b24fc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

path.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ extern void report_linked_checkout_garbage(void);
165165
const char *git_path_##var(struct repository *r) \
166166
{ \
167167
if (!r->cached_paths.var) \
168-
r->cached_paths.var = git_pathdup(filename); \
168+
r->cached_paths.var = repo_git_path(r, filename); \
169169
return r->cached_paths.var; \
170170
}
171171

0 commit comments

Comments
 (0)