Lines Matching refs:fd

128     int		fd = 0;  in readfile()  local
469 fd = mch_open((char *)fname, O_RDONLY | O_EXTRA, 0); in readfile()
473 || (fd = mch_open((char *)fname, O_RDWR | O_EXTRA, 0)) < 0) in readfile()
477 fd = mch_open((char *)fname, O_RDONLY | O_EXTRA, 0); in readfile()
482 if (fd < 0) // cannot open at all in readfile()
610 close(fd); in readfile()
650 close(fd); in readfile()
677 close(fd); // ignore errors in readfile()
725 || (fd = mch_open((char *)fname, O_RDONLY | O_EXTRA, 0)) < 0)) in readfile()
729 if (fd < 0) in readfile()
825 len = read_eintr(fd, firstline, 80); in readfile()
826 vim_lseek(fd, (off_T)0L, SEEK_SET); in readfile()
888 else if (read_stdin || vim_lseek(fd, (off_T)0L, SEEK_SET) != 0) in readfile()
1048 tmpname = readfile_charconvert(fname, fenc, &fd); in readfile()
1053 if (fd < 0) in readfile()
1289 size = read_eintr(fd, ptr, size); in readfile()
2223 || vim_lseek(fd, (off_T)0L, SEEK_SET) in readfile()
2326 close(fd); // errors are ignored in readfile()
2330 int fdflags = fcntl(fd, F_GETFD); in readfile()
2333 (void)fcntl(fd, F_SETFD, fdflags | FD_CLOEXEC); in readfile()
2960 int fd = 0; in check_file_readonly() local
2970 (fd = mch_open((char *)fname, O_RDWR | O_EXTRA, 0)) < 0 in check_file_readonly()
2971 ? TRUE : (close(fd), FALSE) in check_file_readonly()
2982 vim_fsync(int fd) in vim_fsync() argument
2987 r = fcntl(fd, F_FULLFSYNC); in vim_fsync()
2990 r = fsync(fd); in vim_fsync()
5630 read_eintr(int fd, void *buf, size_t bufsize) in read_eintr() argument
5636 ret = vim_read(fd, buf, bufsize); in read_eintr()
5648 write_eintr(int fd, void *buf, size_t bufsize) in write_eintr() argument
5657 wlen = vim_write(fd, (char *)buf + ret, bufsize - ret); in write_eintr()