os_resolve_shortcut: initial port from Vim source

This commit is contained in:
Justin M. Keyes
2016-05-29 03:40:35 -04:00
parent aa2c439940
commit 771d42e426
3 changed files with 136 additions and 5 deletions

View File

@@ -13592,11 +13592,12 @@ static void f_resolve(typval_T *argvars, typval_T *rettv)
{
char_u *v = NULL;
v = mch_resolve_shortcut(p);
if (v != NULL)
v = os_resolve_shortcut(p);
if (v != NULL) {
rettv->vval.v_string = v;
else
} else {
rettv->vval.v_string = vim_strsave(p);
}
}
#else
# ifdef HAVE_READLINK