/external/bison/lib/ |
H A D | fd-safer-flag.c | 40 fd_safer_flag (int fd, int flag) argument 42 if (STDIN_FILENO <= fd && fd <= STDERR_FILENO) 44 int f = dup_safer_flag (fd, flag); 46 close (fd); 48 fd = f; 51 return fd;
|
H A D | fd-safer.c | 37 fd_safer (int fd) argument 39 if (STDIN_FILENO <= fd && fd <= STDERR_FILENO) 41 int f = dup_safer (fd); 43 close (fd); 45 fd = f; 48 return fd;
|
H A D | pipe-safer.c | 31 pipe_safer (int fd[2]) argument 34 if (pipe (fd) == 0) 39 fd[i] = fd_safer (fd[i]); 40 if (fd[i] < 0) 43 close (fd[1 - i]);
|
H A D | pipe2-safer.c | 31 pipe2_safer (int fd[2], int flags) argument 34 if (pipe2 (fd, flags) == 0) 39 fd[i] = fd_safer_flag (fd[i], flags); 40 if (fd[i] < 0) 43 close (fd[1 - i]);
|
H A D | pipe2.c | 40 pipe2 (int fd[2], int flags) argument 42 /* Mingw _pipe() corrupts fd on failure; also, if we succeed at 44 to leave fd unchanged: http://austingroupbugs.net/view.php?id=467 */ 46 tmp[0] = fd[0]; 47 tmp[1] = fd[1]; 58 int result = pipe2 (fd, flags); 79 if (_pipe (fd, 4096, flags & ~O_NONBLOCK) < 0) 81 fd[0] = tmp[0]; 82 fd[1] = tmp[1]; 92 if (set_nonblocking_flag (fd[ [all...] |
H A D | close.c | 24 #include "fd-hook.h" 31 close_nothrow (int fd) argument 37 result = close (fd); 55 rpl_close (int fd) argument 58 int retval = execute_all_close_hooks (close_nothrow, fd); 60 int retval = close_nothrow (fd); 65 _gl_unregister_fd (fd);
|
H A D | cloexec.h | 38 int dup_cloexec (int fd);
|
H A D | dup-safer.c | 31 dup_safer (int fd) argument 33 return fcntl (fd, F_DUPFD, STDERR_FILENO + 1);
|
H A D | dup2.c | 44 ms_windows_dup2 (int fd, int desired_fd) argument 48 /* If fd is closed, mingw hangs on dup2 (fd, fd). If fd is open, 49 dup2 (fd, fd) returns 0, but all further attempts to use fd in 51 if (fd == desired_fd) 53 if ((HANDLE) _get_osfhandle (fd) 91 rpl_dup2(int fd, int desired_fd) argument 121 dupfd(int fd, int desired_fd) argument 138 dup2(int fd, int desired_fd) argument [all...] |
H A D | binary-io.h | 33 /* set_binary_mode (fd, mode) 34 sets the binary/text I/O mode of file descriptor fd to the given mode 50 set_binary_mode (int fd, int mode) 52 (void) fd; 58 /* SET_BINARY (fd); 59 changes the file descriptor fd to perform binary I/O. */ 65 # define SET_BINARY(fd) ((void) (!isatty (fd) ? (set_binary_mode (fd, O_BINARY), 0) : 0)) 67 # define SET_BINARY(fd) ((voi [all...] |
H A D | fd-hook.h | 32 typedef int (*gl_close_fn) (int fd); 35 typedef int (*gl_ioctl_fn) (int fd, int request, void *arg); 51 int fd); 57 int fd, int request, void *arg); 68 int fd); 74 int fd); 78 extern int execute_all_close_hooks (gl_close_fn primary, int fd); 88 int fd, int request, void *arg); 94 int fd, int request, void *arg); 99 int fd, in [all...] |
/external/qemu/android/protocol/ |
H A D | attach-ui-proxy.h | 24 * fd - Socket descriptor for the proxy. 28 extern int attachUiProxy_create(int fd);
|
H A D | core-commands-impl.h | 25 * fd - Socket descriptor for the service. 29 extern int coreCmdImpl_create(int fd);
|
H A D | user-events-impl.h | 24 * fd - Socket descriptor for the service. 28 extern int userEventsImpl_create(int fd);
|
H A D | ui-commands-proxy.h | 24 * fd - Socket descriptor for the proxy. 28 extern int uiCmdProxy_create(int fd);
|
/external/e2fsprogs/tests/progs/ |
H A D | random_exercise.c | 50 int fd; local 53 fd = ((int) random()) % MAXFDS; 54 if (fd > 2) 55 return fd; 59 unsigned int get_inode_num(int fd) argument 63 if (fstat(fd, &st) < 0) { 74 int fd; local 83 fd = open(template, O_RDONLY, 0600); 84 printf("Created temp directory %s, fd = %d\n", 85 template, fd); 101 truncate_file(int fd) argument 116 unlink_file(int fd) argument 130 close_file(int fd) argument 144 int i, fd; local [all...] |
/external/e2fsprogs/lib/ext2fs/ |
H A D | getsectsize.c | 26 #include <linux/fd.h> 46 int fd; local 49 fd = open64(file, O_RDONLY); 51 fd = open(file, O_RDONLY); 53 if (fd < 0) 57 if (ioctl(fd, BLKSSZGET, sectsize) >= 0) { 58 close(fd); 63 close(fd); 72 int fd; local 75 fd [all...] |
/external/chromium/base/ |
H A D | file_descriptor_posix.h | 21 : fd(-1), 25 : fd(ifd), 29 return (fd == other.fd && auto_close == other.auto_close); 34 return other.fd < fd; 37 int fd; member in struct:base::FileDescriptor
|
/external/openssh/openbsd-compat/ |
H A D | daemon.c | 54 int fd; local 71 if (!noclose && (fd = open(_PATH_DEVNULL, O_RDWR, 0)) != -1) { 72 (void)dup2(fd, STDIN_FILENO); 73 (void)dup2(fd, STDOUT_FILENO); 74 (void)dup2(fd, STDERR_FILENO); 75 if (fd > 2) 76 (void)close (fd);
|
/external/chromium/base/test/ |
H A D | test_file_util_linux.cc | 16 int fd = open(file.value().c_str(), O_RDONLY); local 17 if (fd < 0) 19 if (fdatasync(fd) != 0) 21 if (posix_fadvise(fd, 0, 0, POSIX_FADV_DONTNEED) != 0) 23 close(fd);
|
/external/valgrind/main/none/tests/ |
H A D | closeall.c | 9 int fd; local 13 for ( fd = 3; fd < lim.rlim_cur; fd++ ) 14 close( fd );
|
/external/valgrind/main/memcheck/tests/ |
H A D | erringfds.stdout.exp | 0 fd = -1
|
H A D | erringfds.c | 10 int fd, n; local 12 fd = open("foo/bar/xyzzy", O_RDONLY); /* fails */ 13 printf("fd = %d\n", fd); 14 n = read ( fd, buf, 10 );
|
H A D | fwrite.c | 8 int fd = open("/dev/null", O_WRONLY); local 9 if (fd < 0) { 12 (void)write(fd, arr, 10); 13 (void)close(fd);
|
/external/skia/src/utils/android/ |
H A D | ashmem.c | 36 int fd, ret; local 38 fd = open(ASHMEM_DEVICE, O_RDWR); 39 if (fd < 0) 40 return fd; 46 ret = ioctl(fd, ASHMEM_SET_NAME, buf); 51 ret = ioctl(fd, ASHMEM_SET_SIZE, size); 55 return fd; 58 close(fd); 62 int ashmem_set_prot_region(int fd, int prot) argument 64 return ioctl(fd, ASHMEM_SET_PROT_MAS 67 ashmem_pin_region(int fd, size_t offset, size_t len) argument 73 ashmem_unpin_region(int fd, size_t offset, size_t len) argument 79 ashmem_get_size_region(int fd) argument [all...] |