aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/path.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/path.c b/src/path.c
index 6eecf084e..f93894c7b 100644
--- a/src/path.c
+++ b/src/path.c
@@ -283,14 +283,14 @@ char * prependCwdToPathDup(char * path) {
len = strlen(ret);
if(ret[len-1]!='/') {
strncat(ret,"/",MAXPATHLEN-len);
- len = strlen(path);
+ len = strlen(ret);
}
strncat(ret,path,MAXPATHLEN-len);
len = strlen(ret);
}
if(ret[len-1]!='/') {
strncat(ret,"/",MAXPATHLEN-len);
- len = strlen(path);
+ len = strlen(ret);
}
return realloc(ret,len+1);