diff options
author | Thomas Wienecke <wienecke.t@gmail.com> | 2014-03-14 22:55:14 +0100 |
---|---|---|
committer | Thiago de Arruda <tpadilha84@gmail.com> | 2014-03-15 11:50:22 -0300 |
commit | 1949acc806e89dc0d2766b2b41eae1cac3186642 (patch) | |
tree | 1baad3b84e7ce42b7394e8ccc66670845cc5ccaf /src/undo.c | |
parent | c83e8b4dc74ba010e0279b67ef8ffa14103d89f6 (diff) | |
download | rneovim-1949acc806e89dc0d2766b2b41eae1cac3186642.tar.gz rneovim-1949acc806e89dc0d2766b2b41eae1cac3186642.tar.bz2 rneovim-1949acc806e89dc0d2766b2b41eae1cac3186642.zip |
Revive vim_fname (-> os_file_exists); fix misuse of mch_getperm.
* Move vim_fname from misc1 to os/fs:os_file_exists.
* Add unit tests for os_file_exists.
* Replace misuse of mch_getperm with os_file_exists.
Diffstat (limited to 'src/undo.c')
-rw-r--r-- | src/undo.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/undo.c b/src/undo.c index d1c3cc92ed..67e7fe7a36 100644 --- a/src/undo.c +++ b/src/undo.c @@ -1173,7 +1173,7 @@ void u_write_undo(char_u *name, int forceit, buf_T *buf, char_u *hash) /* If the undo file already exists, verify that it actually is an undo * file, and delete it. */ - if (mch_getperm(file_name) >= 0) { + if (os_file_exists(file_name)) { if (name == NULL || !forceit) { /* Check we can read it and it's an undo file. */ fd = mch_open((char *)file_name, O_RDONLY|O_EXTRA, 0); |