aboutsummaryrefslogtreecommitdiff
path: root/cache.h
diff options
context:
space:
mode:
authorMichael Haggerty <mhagger@alum.mit.edu>2012-10-28 17:16:22 +0100
committerJeff King <peff@peff.net>2012-10-29 02:34:58 -0400
commite3e46cdbd45c2e7383df9de1787e23489dc66dbc (patch)
treead73b04f0a16f9c707f26d20a41ce87dddc64502 /cache.h
parentd6052abca39fc84fed4f3248be042cfb6bf635d5 (diff)
downloadgit-e3e46cdbd45c2e7383df9de1787e23489dc66dbc.tar.gz
git-e3e46cdbd45c2e7383df9de1787e23489dc66dbc.tar.xz
Introduce new function real_path_if_valid()
The function is like real_path(), except that it returns NULL on error instead of dying. Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu> Signed-off-by: Jeff King <peff@peff.net>
Diffstat (limited to 'cache.h')
-rw-r--r--cache.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/cache.h b/cache.h
index a58df84bd..b0d75bcb0 100644
--- a/cache.h
+++ b/cache.h
@@ -714,6 +714,7 @@ static inline int is_absolute_path(const char *path)
}
int is_directory(const char *);
const char *real_path(const char *path);
+const char *real_path_if_valid(const char *path);
const char *absolute_path(const char *path);
const char *relative_path(const char *abs, const char *base);
int normalize_path_copy(char *dst, const char *src);