summaryrefslogtreecommitdiff
path: root/Src/hashtable.c
diff options
context:
space:
mode:
Diffstat (limited to 'Src/hashtable.c')
-rw-r--r--Src/hashtable.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/Src/hashtable.c b/Src/hashtable.c
index 1f2789d07..8987c8597 100644
--- a/Src/hashtable.c
+++ b/Src/hashtable.c
@@ -1566,6 +1566,15 @@ dircache_set(char **name, char *value)
*name = NULL;
} else {
/*
+ * As the function path has been resolved to a particular
+ * location, we'll store it as an absolute path.
+ */
+ if (*value != '/') {
+ value = zhtricat(metafy(zgetcwd(), -1, META_HEAPDUP),
+ "/", value);
+ value = xsymlink(value, 1);
+ }
+ /*
* We'll maintain the cache at exactly the right size rather
* than overallocating. The rationale here is that typically
* we'll get a lot of functions in a small number of directories