summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLibravatar Han-Wen Nienhuys <hanwen@google.com>2017-09-26 13:21:48 +0200
committerLibravatar Junio C Hamano <gitster@pobox.com>2017-09-27 09:13:47 +0900
commitd83d846e84d6ba6c7c4221d2681dfde820949362 (patch)
tree419e19a5f114d409897f616929020e9cf0e74a8f
parentSync with 2.14.2 (diff)
downloadtgif-d83d846e84d6ba6c7c4221d2681dfde820949362.tar.xz
real_path: clarify return value ownership
Signed-off-by: Han-Wen Nienhuys <hanwen@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rw-r--r--abspath.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/abspath.c b/abspath.c
index 708aff8d42..9857985329 100644
--- a/abspath.c
+++ b/abspath.c
@@ -202,6 +202,10 @@ error_out:
return retval;
}
+/*
+ * Resolve `path` into an absolute, cleaned-up path. The return value
+ * comes from a shared buffer.
+ */
const char *real_path(const char *path)
{
static struct strbuf realpath = STRBUF_INIT;