/external/strace/tests-m32/ |
wait4.c | 105 int fds[2]; local 106 if (pipe(fds)) 155 if (pipe(fds))
|
/external/strace/tests-mx32/ |
prctl-seccomp-filter-v.c | 100 int fds[2]; local 126 if (pipe(fds))
|
readahead.c | 59 static const int fds[] = { variable 94 for (i = 0; i < ARRAY_SIZE(fds); i++) 97 rc = readahead(fds[i], offsets[j], counts[k]); 100 fds[i], (long long) offsets[j],
|
scm_rights.c | 40 int fds[ac]; local 71 assert((fds[0] = open("/dev/null", O_RDWR)) == 4); 73 assert((fds[i] = open(av[i], O_RDONLY)) == i + 4); 75 unsigned int cmsg_size = CMSG_SPACE(sizeof(fds)); 80 cmsg->cmsg_len = CMSG_LEN(sizeof(fds)); 81 memcpy(CMSG_DATA(cmsg), fds, sizeof(fds)); local 92 assert(close(fds[i]) == 0); 93 fds[i] = 0;
|
siginfo.c | 50 int fds[2]; local 51 if (pipe(fds)) 96 if (pipe(fds)) 126 if (pipe(fds))
|
wait4.c | 105 int fds[2]; local 106 if (pipe(fds)) 155 if (pipe(fds))
|
/frameworks/wilhelm/tests/sandbox/ |
getch.c | 38 fd_set fds; local 39 FD_ZERO(&fds); // not in original posting to stackoverflow 40 FD_SET(0, &fds); 41 return select(1, &fds, NULL, NULL, &tv);
|
/system/core/libion/tests/ |
allocate_test.cpp | 98 int fds[16]; local 112 fds[i] = map_fd; 116 ASSERT_EQ(0, close(fds[i]));
|
/system/extras/tests/storage/ |
opentest.c | 30 int *fds; local 64 fds = malloc(nfiles * sizeof(int)); 65 if (fds == 0) { 66 fprintf(stderr, "Unable to malloc array of %d fds\n", nfiles); 84 fds[i] = open(name, O_WRONLY | O_CREAT, 0666); 85 if (fds[i] < 0) {
|
/system/media/audio_utils/tests/ |
getch.c | 38 fd_set fds; local 39 FD_ZERO(&fds); // not in original posting to stackoverflow 40 FD_SET(0, &fds); 41 return select(1, &fds, NULL, NULL, &tv);
|
/bionic/tests/ |
sys_select_test.cpp | 29 fd_set fds; local 30 FD_ZERO(&fds); 33 EXPECT_FALSE(FD_ISSET(i, &fds)); 36 FD_SET(0, &fds); 37 EXPECT_TRUE(FD_ISSET(0, &fds)); 38 EXPECT_FALSE(FD_ISSET(1, &fds)); 39 FD_SET(1, &fds); 40 EXPECT_TRUE(FD_ISSET(0, &fds)); 41 EXPECT_TRUE(FD_ISSET(1, &fds)); 42 FD_CLR(0, &fds); 53 int fds[2]; local [all...] |
/device/google/cuttlefish_common/common/libs/fs/ |
shared_fd_test.cpp | 48 SharedFD fds[2]; local 49 SharedFD::Pipe(fds, fds + 1); 50 ssize_t rval = client->SendMsgAndFDs(hdr, 0, fds); 62 SharedFD fds[2]; local 63 peer->RecvMsgAndFDs(hdr, 0, &fds); 65 EXPECT_TRUE(fds[0]->IsOpen()); 66 EXPECT_TRUE(fds[1]->IsOpen()); 67 EXPECT_EQ(sizeof(pipe_message), fds[1]->Write(pipe_message, sizeof(pipe_message))); 68 EXPECT_EQ(sizeof(pipe_message), fds[0]->Read(buf, sizeof(buf))) [all...] |
/device/google/cuttlefish_common/host/libs/ivserver/ |
hald_client.cc | 87 // Send Host, Guest and SharedMemory FDs associated with this region. 116 cvd::SharedFD fds[3] = {guest_to_host_efd, host_to_guest_efd, local 118 rval = client_socket_->SendMsgAndFDs<3>(hdr, MSG_NOSIGNAL, fds);
|
qemu_client.cc | 113 cvd::SharedFD fds[] = {socket}; local 114 int rval = client_socket_->SendMsgAndFDs(hdr, 0, fds);
|
/external/e2fsprogs/lib/ |
fpopen.c | 43 int fds[2]; local 93 if (pipe(fds) < 0) 102 close(fds[1]); 103 dup2(fds[0], 0); 105 close(fds[0]); 106 dup2(fds[1], 1); 108 dup2(fds[1], 2); 114 return fdopen(do_stdin ? fds[1] : fds[0], mode);
|
/external/google-breakpad/src/client/linux/crash_generation/ |
crash_generation_client.cc | 52 int fds[2]; local 53 if (sys_pipe(fds) < 0) 73 *p = fds[1]; 76 sys_close(fds[1]); 78 sys_close(fds[0]); 84 IGNORE_RET(HANDLE_EINTR(sys_read(fds[0], &b, 1))); 85 sys_close(fds[0]);
|
/external/libchrome/base/posix/ |
unix_domain_socket_linux_unittest.cc | 31 int fds[2]; local 32 ASSERT_EQ(0, socketpair(AF_UNIX, SOCK_SEQPACKET, 0, fds)); 33 ScopedFD scoped_fd0(fds[0]); 34 ScopedFD scoped_fd1(fds[1]); 40 Bind(IgnoreResult(&UnixDomainSocket::SendRecvMsg), fds[1], 47 UnixDomainSocket::RecvMsg(fds[0], buffer, sizeof(buffer), 67 int fds[2]; local 68 ASSERT_EQ(0, socketpair(AF_UNIX, SOCK_SEQPACKET, 0, fds)); 69 ScopedFD scoped_fd1(fds[1]); 70 ASSERT_EQ(0, IGNORE_EINTR(close(fds[0]))) 85 int fds[2]; local 112 int fds[2]; local 142 int fds[2]; local [all...] |
/external/libchrome/base/test/ |
multiprocess_test_android.cc | 44 android::ScopedJavaLocalRef<jobjectArray> fds = local 57 env, android::GetApplicationContext(), j_argv, fds);
|
/external/libdrm/ |
libsync.h | 63 struct pollfd fds = {0}; local 66 fds.fd = fd; 67 fds.events = POLLIN; 70 ret = poll(&fds, 1, timeout); 72 if (fds.revents & (POLLERR | POLLNVAL)) {
|
/external/libdrm/tests/kms/ |
kms-steal-crtc.c | 124 fd_set fds; local 130 FD_ZERO(&fds); 131 FD_SET(STDIN_FILENO, &fds); 133 err = select(nfds, &fds, NULL, NULL, &timeout); 143 if (FD_ISSET(STDIN_FILENO, &fds))
|
/external/libmojo/mojo/edk/embedder/ |
platform_channel_pair_posix.cc | 62 int fds[2]; local 66 PCHECK(imc_socketpair(fds) == 0); 68 PCHECK(socketpair(AF_UNIX, SOCK_STREAM, 0, fds) == 0); 71 PCHECK(fcntl(fds[0], F_SETFL, O_NONBLOCK) == 0); 73 PCHECK(fcntl(fds[1], F_SETFL, O_NONBLOCK) == 0); 80 PCHECK(setsockopt(fds[0], SOL_SOCKET, SO_NOSIGPIPE, &no_sigpipe, 82 PCHECK(setsockopt(fds[1], SOL_SOCKET, SO_NOSIGPIPE, &no_sigpipe, 87 server_handle_.reset(PlatformHandle(fds[0])); 89 client_handle_.reset(PlatformHandle(fds[1]));
|
/external/ltp/testcases/kernel/syscalls/epoll_ctl/ |
epoll_ctl02.c | 59 int *fds; member in struct:testcase 104 TEST(epoll_ctl(*tc->epfds, tc->opt, *tc->fds, tc->ts_event));
|
/external/ltp/testcases/kernel/syscalls/socketpair/ |
socketpair01.c | 34 static int fds[2]; variable 45 {0, SOCK_STREAM, 0, fds, -1, EAFNOSUPPORT, "invalid domain"}, 46 {PF_INET, 75, 0, fds, -1, EINVAL, "invalid type"}, 47 {PF_UNIX, SOCK_DGRAM, 0, fds, 0, 0, "UNIX domain dgram"}, 48 {PF_INET, SOCK_RAW, 0, fds, -1, EPROTONOSUPPORT, "raw open as non-root"}, 53 {PF_INET, SOCK_DGRAM, 17, fds, -1, EOPNOTSUPP, "UDP socket"}, 54 {PF_INET, SOCK_DGRAM, 6, fds, -1, EPROTONOSUPPORT, "TCP dgram"}, 55 {PF_INET, SOCK_STREAM, 6, fds, -1, EOPNOTSUPP, "TCP socket"}, 56 {PF_INET, SOCK_STREAM, 1, fds, -1, EPROTONOSUPPORT, "ICMP stream"} 66 SAFE_CLOSE(fds[0]) [all...] |
socketpair02.c | 38 static int fds[2]; variable 57 TEST(socketpair(PF_UNIX, tc->type, 0, fds)); 63 res = SAFE_FCNTL(fds[i], tc->fl_flag); 66 tst_res(TFAIL, "socketpair() failed to set %s flag for fds[%d]", 72 tst_res(TFAIL, "socketpair() failed to set %s flag for fds[%d]", 81 SAFE_CLOSE(fds[0]); 82 SAFE_CLOSE(fds[1]); 87 if (fds[0] > 0) 88 SAFE_CLOSE(fds[0]); 90 if (fds[1] > 0 [all...] |
/external/minijail/ |
system_unittest.cc | 79 int fds[2]; local 80 EXPECT_EQ(0, pipe(fds)); 81 // This should close fds[1] and return fds[0]. 82 EXPECT_EQ(fds[0], setup_pipe_end(fds, 0)); 84 EXPECT_EQ(-1, close(fds[1])); 85 EXPECT_EQ(0, close(fds[0])); 90 int fds[2]; local 91 EXPECT_EQ(0, pipe(fds)); [all...] |