/freebsd-11-stable/lib/libulog/ |
H A D | ulog_login_pseudo.c | 46 ulog_exec_helper(int fd, char const * const argv[]) argument 62 if (dup2(fd, STDIN_FILENO) == -1) 79 ulog_login_pseudo(int fd, const char *host) argument 83 ulog_exec_helper(fd, args); 87 ulog_logout_pseudo(int fd) argument 91 ulog_exec_helper(fd, args);
|
/freebsd-11-stable/lib/libusbhid/ |
H A D | descr_compat.c | 52 hid_set_immed_compat7(int fd, int enable) argument 54 return (ioctl(fd, USB_SET_IMMED, &enable)); 58 hid_get_report_id_compat7(int fd) argument 62 if (ioctl(fd, USB_GET_REPORT_ID, &temp) < 0) 69 hid_get_report_desc_compat7(int fd) argument 74 if (ioctl(fd, USB_GET_REPORT_DESC, &rep) < 0)
|
/freebsd-11-stable/crypto/heimdal/lib/krb5/ |
H A D | crypto-rand.c | 48 int fd; local 49 fd = open(seedfile, O_RDONLY | O_BINARY | O_CLOEXEC); 50 if (fd >= 0) { 52 rk_cloexec(fd); 53 ret = read(fd, buf, sizeof(buf)); 56 close(fd);
|
/freebsd-11-stable/usr.sbin/procctl/ |
H A D | procctl.c | 58 int fd; local 65 fd = open(buf, O_RDWR); 66 if (fd == -1) { 72 if (ioctl(fd, PIOCBIC, ~0) == -1) 74 if (ioctl(fd, PIOCCONT, 0) == -1 && errno != EINVAL) 76 close(fd);
|
/freebsd-11-stable/contrib/netbsd-tests/lib/libc/sys/ |
H A D | t_socketpair.c | 50 connected(int fd) argument 54 ATF_REQUIRE(getpeername(fd, (struct sockaddr*)(void *)&addr, 61 int fd[2], i; local 72 ATF_REQUIRE(socketpair(domain, type | flags, 0, fd) == 0); 74 ATF_REQUIRE(fd[0] == 3); 75 ATF_REQUIRE(fd[1] == 4); 77 connected(fd[0]); 78 connected(fd[1]); 81 ATF_REQUIRE((fcntl(fd[0], F_GETFD) & FD_CLOEXEC) != 0); 82 ATF_REQUIRE((fcntl(fd[ 109 int fd[2]; local 126 int fd; local [all...] |
H A D | t_dup.c | 60 int fd, fd1, fd2; local 78 fd = dup(fd1); 80 fd = dup2(fd1, fd2); 82 fd = dup3(fd1, fd2, O_CLOEXEC); 84 fd = -1; 87 ATF_REQUIRE(fd >= 0); 92 ATF_REQUIRE(fstat(fd, &st) == 0); 98 (void)close(fd); 114 int fd, fd1, fd2; local 122 fd 142 int fd; local 207 int fd; local 300 int *buf, fd, sta; local [all...] |
H A D | t_truncate.c | 57 int fd; local 59 fd = open(path, O_RDWR | O_CREAT, 0600); 60 ATF_REQUIRE(fd >= 0); 66 ATF_REQUIRE(ftruncate(fd, sizes[i]) == 0); 67 ATF_REQUIRE(fstat(fd, &st) == 0); 75 (void)close(fd); 93 int fd; local 95 fd = open("/etc/passwd", O_RDONLY, 0400); 96 ATF_REQUIRE(fd >= 0); 102 ATF_REQUIRE_ERRNO(EINVAL, ftruncate(fd, 99 117 int fd; local [all...] |
/freebsd-11-stable/contrib/llvm-project/lldb/include/lldb/Utility/ |
H A D | SelectHelper.h | 33 // cause FD_SET() to be called prior to calling select using the "fd" 35 void FDSetRead(lldb::socket_t fd); 36 void FDSetWrite(lldb::socket_t fd); 37 void FDSetError(lldb::socket_t fd); 43 bool FDIsSetRead(lldb::socket_t fd) const; 44 bool FDIsSetWrite(lldb::socket_t fd) const; 45 bool FDIsSetError(lldb::socket_t fd) const;
|
/freebsd-11-stable/contrib/llvm-project/lldb/include/lldb/Host/ |
H A D | Terminal.h | 22 Terminal(int fd = -1) : m_fd(fd) {} 30 void SetFileDescriptor(int fd) { m_fd = fd; } argument 57 /// Save the TTY state for \a fd. 59 /// Save the current state of the TTY for the file descriptor "fd" and if 63 /// \param[in] fd 71 /// Returns \b true if \a fd describes a TTY and if the state 73 bool Save(int fd, bool save_process_group); 154 /// state is saved for the file descriptor \a fd an [all...] |
/freebsd-11-stable/sys/cddl/compat/opensolaris/sys/ |
H A D | stat.h | 43 fstat64(int fd, struct stat *sb) argument 47 ret = fstat(fd, sb); 50 (void)ioctl(fd, DIOCGMEDIASIZE, &sb->st_size);
|
H A D | file.h | 42 getf(int fd, cap_rights_t *rightsp) argument 46 if (fget(curthread, fd, rightsp, &fp) == 0) 52 releasef(int fd) argument 58 if (fget(curthread, fd, cap_rights_init(&rights), &fp) == 0) {
|
/freebsd-11-stable/crypto/heimdal/lib/roken/ |
H A D | cloexec.c | 39 rk_cloexec(int fd) argument 44 ret = fcntl(fd, F_GETFD); 47 if (fcntl(fd, F_SETFD, ret | FD_CLOEXEC) == -1)
|
/freebsd-11-stable/stand/libsa/ |
H A D | readdir.c | 34 readdirfd(int fd) argument 37 struct open_file *f = &files[fd]; 39 if ((unsigned)fd >= SOPEN_MAX || !(f->f_flags & F_READ)) {
|
/freebsd-11-stable/contrib/gdb/gdb/config/rs6000/ |
H A D | xm-rs6000.h | 83 int fd = fileno (stdout); \ 84 if (isatty (fd)) { \ 87 val = atoi (termdef (fd, 'l')); \ 90 val = atoi (termdef (fd, 'c')); \
|
/freebsd-11-stable/contrib/sendmail/libsmutil/ |
H A D | lockfile.c | 23 ** fd -- the file descriptor of the file. 37 lockfile(fd, filename, ext, type) 38 int fd; 59 if (fcntl(fd, action, &lfd) >= 0) 76 if (flock(fd, type) >= 0)
|
/freebsd-11-stable/libexec/rtld-elf/ |
H A D | rtld_printf.h | 37 int rtld_vfdprintf(int fd, const char *fmt, va_list ap); 38 int rtld_fdprintf(int fd, const char *fmt, ...) __printflike(2, 3); 39 void rtld_fdputstr(int fd, const char *str); 40 void rtld_fdputchar(int fd, int c);
|
/freebsd-11-stable/libexec/tftpd/ |
H A D | tftp-file.h | 29 int write_init(int fd, FILE *f, const char *mode); 33 int read_init(int fd, FILE *f, const char *mode);
|
/freebsd-11-stable/tests/sys/file/ |
H A D | fcntlflags_test.c | 46 int fd, flags1, flags2, flags3; local 48 fd = open(path, omode); 49 if (fd == -1) 55 flags1 = fcntl(fd, F_GETFL); 65 if (fcntl(fd, F_SETFL, flags1) == -1) 71 flags2 = fcntl(fd, F_GETFL); 81 if (fcntl(fd, F_SETFL, flags2 | O_NONBLOCK) == -1) 87 flags3 = fcntl(fd, F_GETFL); 97 (void)close(fd);
|
/freebsd-11-stable/usr.bin/tset/ |
H A D | misc.c | 48 register int fd, nr, nw; local 51 if ((fd = open(file, O_RDONLY, 0)) < 0) 54 while ((nr = read(fd, buf, sizeof(buf))) > 0) 59 (void)close(fd);
|
/freebsd-11-stable/sbin/comcontrol/ |
H A D | comcontrol.c | 58 int fd; local 67 fd = STDIN_FILENO; 69 fd = open(argv[1], O_RDONLY|O_NONBLOCK, 0); 70 if (fd < 0) { 76 if (ioctl(fd, TIOCMGDTRWAIT, &dtrwait) < 0) { 83 if (ioctl(fd, TIOCGDRAINWAIT, &drainwait) < 0) { 115 if (ioctl(fd, TIOCMSDTRWAIT, &dtrwait) < 0) { 121 if (ioctl(fd, TIOCSDRAINWAIT, &drainwait) < 0) { 128 close(fd);
|
/freebsd-11-stable/usr.bin/unifdef/ |
H A D | unifdef.h | 50 int fd = mkstemp(tmp); local 51 if (fd < 0) return (NULL); 52 fchmod(fd, mode & (S_IRWXU|S_IRWXG|S_IRWXO)); 53 return (fdopen(fd, "wb"));
|
/freebsd-11-stable/usr.sbin/bluetooth/sdpd/ |
H A D | server.h | 83 int32_t server_prepare_service_search_response(server_p srv, int32_t fd); 84 int32_t server_send_service_search_response(server_p srv, int32_t fd); 86 int32_t server_prepare_service_attribute_response(server_p srv, int32_t fd); 87 int32_t server_send_service_attribute_response(server_p srv, int32_t fd); 89 int32_t server_prepare_service_search_attribute_response(server_p srv, int32_t fd); 93 int32_t server_prepare_service_register_response(server_p srv, int32_t fd); 94 int32_t server_send_service_register_response(server_p srv, int32_t fd); 96 int32_t server_prepare_service_unregister_response(server_p srv, int32_t fd); 100 int32_t server_prepare_service_change_response(server_p srv, int32_t fd);
|
/freebsd-11-stable/contrib/llvm-project/lldb/source/Host/common/ |
H A D | FileAction.cpp | 33 bool FileAction::Open(int fd, const FileSpec &file_spec, bool read, argument 35 if ((read || write) && fd >= 0 && file_spec) { 37 m_fd = fd; 52 bool FileAction::Close(int fd) { argument 54 if (fd >= 0) { 56 m_fd = fd; 61 bool FileAction::Duplicate(int fd, int dup_fd) { argument 63 if (fd >= 0 && dup_fd >= 0) { 65 m_fd = fd; 75 stream.Printf("close fd [all...] |
/freebsd-11-stable/stand/liblua/ |
H A D | lstd.c | 38 int fd, m, o; local 63 fd = open(filename, m | o); 64 if (fd < 0) 69 close(fd); 73 if (fstat(fd, &st) != 0) { 75 close(fd); 79 f->fd = fd; 101 r = (size_t)read(stream->fd, ptr, size * count); 114 w = write(stream->fd, pt 168 int fd; local 180 fdopendir(int fd) argument [all...] |
/freebsd-11-stable/tools/regression/sockets/zerosend/ |
H A D | zerosend.c | 49 try_0send(const char *test, int fd) argument 55 len = send(fd, &ch, 0, 0); 63 try_0write(const char *test, int fd) argument 69 len = write(fd, &ch, 0); 247 int fd[2]; local 249 setup_udp("udp_0send", fd, PORT1, PORT2); 250 try_0send("udp_0send", fd[0]); 251 close_both(fd); 253 setup_udp("udp_0write", fd, PORT1 + 10, PORT2 + 10); 254 try_0write("udp_0write", fd[ [all...] |