os_unix: Use libuv uv_cwd instead of getcwd/getwd.

This commit is contained in:
Thomas Wienecke
2014-02-25 17:03:04 +01:00
committed by Thiago de Arruda
parent d342257ae4
commit 1e2da25d3d
8 changed files with 19 additions and 19 deletions

View File

@@ -1244,24 +1244,6 @@ static char * strerror(int err)
}
#endif
/*
* Get name of current directory into buffer 'buf' of length 'len' bytes.
* Return OK for success, FAIL for failure.
*/
int mch_dirname(char_u *buf, int len)
{
#if defined(USE_GETCWD)
if (getcwd((char *)buf, len) == NULL) {
STRCPY(buf, strerror(errno));
return FAIL;
}
return OK;
#else
return getwd((char *)buf) != NULL ? OK : FAIL;
#endif
}
/*
* Get absolute file name into "buf[len]".
*