aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/undo.c
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2014-08-16 08:33:21 -0400
committerJustin M. Keyes <justinkz@gmail.com>2014-08-16 08:33:21 -0400
commit640bced2f8bf64098d52841947a3145554d41041 (patch)
tree1787f0df28059d27fe32885bc4b972384ff09c2e /src/nvim/undo.c
parent19207762fd6dccd83b89c96bb1163b0d0440defb (diff)
parent8f4ada5a2a5c1bfe546cf7d67d3531551ff6026c (diff)
downloadrneovim-640bced2f8bf64098d52841947a3145554d41041.tar.gz
rneovim-640bced2f8bf64098d52841947a3145554d41041.tar.bz2
rneovim-640bced2f8bf64098d52841947a3145554d41041.zip
Merge pull request #950 from Hinidu/os_fchown
Implement os_fchown and remove HAVE_FCHOWN
Diffstat (limited to 'src/nvim/undo.c')
-rw-r--r--src/nvim/undo.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/nvim/undo.c b/src/nvim/undo.c
index 96b83a3e2d..8c7b5b38e9 100644
--- a/src/nvim/undo.c
+++ b/src/nvim/undo.c
@@ -1119,10 +1119,7 @@ void u_write_undo(char_u *name, int forceit, buf_T *buf, char_u *hash)
if (os_get_file_info((char *)buf->b_ffname, &file_info_old)
&& os_get_file_info((char *)file_name, &file_info_new)
&& file_info_old.stat.st_gid != file_info_new.stat.st_gid
-# ifdef HAVE_FCHOWN /* sequent-ptx lacks fchown() */
- && fchown(fd, (uid_t)-1, file_info_old.stat.st_gid) != 0
-# endif
- ) {
+ && os_fchown(fd, -1, file_info_old.stat.st_gid) != 0) {
os_setperm(file_name, (perm & 0707) | ((perm & 07) << 3));
}
# ifdef HAVE_SELINUX