diff options
author | Bram Moolenaar <bram@vim.org> | 2011-05-19 14:59:10 +0200 |
---|---|---|
committer | Bram Moolenaar <bram@vim.org> | 2011-05-19 14:59:10 +0200 |
commit | d14042773b7f33b35656afe0c56dada69082c953 (patch) | |
tree | 7d7b42c016367d33caca5dbfc515124fcafe678a | |
parent | dcc678b28a3ce044391a0dd1f51a6b4d52a1a5a3 (diff) | |
download | vim-d14042773b7f33b35656afe0c56dada69082c953.tar.gz |
Problem: When "b" is a symlink to directory "a", resolve("b/") doesn't
result in "a/". (ZyX)
Solution: Remove the trailing slash. (Jean-Rene David)
-rw-r--r-- | src/eval.c | 3 | ||||
-rw-r--r-- | src/version.c | 2 |
2 files changed, 5 insertions, 0 deletions
@@ -14980,7 +14980,10 @@ f_resolve(argvars, rettv) len = STRLEN(p); if (len > 0 && after_pathsep(p, p + len)) + { has_trailing_pathsep = TRUE; + p[len - 1] = NUL; /* the trailing slash breaks readlink() */ + } q = getnextcomp(p); if (*q != NUL) diff --git a/src/version.c b/src/version.c index 1bd18584..b505c294 100644 --- a/src/version.c +++ b/src/version.c @@ -710,6 +710,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 194, +/**/ 193, /**/ 192, |