aboutsummaryrefslogtreecommitdiff
path: root/cache.h
diff options
context:
space:
mode:
authorBrandon Williams <bmwill@google.com>2016-12-12 10:16:53 -0800
committerJunio C Hamano <gitster@pobox.com>2016-12-12 15:22:32 -0800
commita1ae48410dce23c1e81e76aabaeb4eb01b065763 (patch)
tree89bb3be2d33464d8817e39d6b9be11d520db0993 /cache.h
parent05b458c104708141d2fad211d79703b3b99cc5a8 (diff)
downloadgit-a1ae48410dce23c1e81e76aabaeb4eb01b065763.tar.gz
git-a1ae48410dce23c1e81e76aabaeb4eb01b065763.tar.xz
real_path: convert real_path_internal to strbuf_realpath
Change the name of real_path_internal to strbuf_realpath. In addition push the static strbuf up to its callers and instead take as a parameter a pointer to a strbuf to use for the final result. This change makes strbuf_realpath reentrant. Signed-off-by: Brandon Williams <bmwill@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'cache.h')
-rw-r--r--cache.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/cache.h b/cache.h
index a50a61a19..7a8129403 100644
--- a/cache.h
+++ b/cache.h
@@ -1064,6 +1064,8 @@ static inline int is_absolute_path(const char *path)
return is_dir_sep(path[0]) || has_dos_drive_prefix(path);
}
int is_directory(const char *);
+char *strbuf_realpath(struct strbuf *resolved, const char *path,
+ int die_on_error);
const char *real_path(const char *path);
const char *real_path_if_valid(const char *path);
const char *absolute_path(const char *path);