diff --git a/abspath.c b/abspath.c index 39e06b5848..7a5f114382 100644 --- a/abspath.c +++ b/abspath.c @@ -91,6 +91,9 @@ static char *strbuf_realpath_1(struct strbuf *resolved, const char *path, goto error_out; } + if (platform_strbuf_realpath(resolved, path)) + return resolved->buf; + strbuf_addstr(&remaining, path); get_root_part(resolved, &remaining); diff --git a/git-compat-util.h b/git-compat-util.h index 4f0028ce60..00a6db056c 100644 --- a/git-compat-util.h +++ b/git-compat-util.h @@ -560,6 +560,10 @@ static inline int git_has_dir_sep(const char *path) #define query_user_email() NULL #endif +#ifndef platform_strbuf_realpath +#define platform_strbuf_realpath(resolved, path) NULL +#endif + #ifdef __TANDEM #include #include