Searched defs:fds (Results 1 - 25 of 120) sorted by relevance

12345

/external/chromium_org/native_client_sdk/src/libraries/nacl_io/syscalls/
H A Dpoll.c10 int poll(struct pollfd *fds, nfds_t nfds, int timeout) { argument
11 return ki_poll(fds, nfds, timeout);
/external/valgrind/main/none/tests/
H A Dfdleak_pipe.c6 int fds[2]; local
10 (void) DO( pipe(fds) );
H A Dfdleak_socketpair.c8 int fds[2]; local
12 (void) DO( socketpair(AF_UNIX, SOCK_STREAM, PF_UNSPEC, fds) );
H A Dsyscall-restart1.c18 int fds[2]; local
20 if (pipe(fds) == -1) {
43 close(fds[1]);
44 ret = read(fds[0], &ch, 1);
52 close(fds[0]);
56 if (write(fds[1], "x", 1) != -1 || errno != EPIPE)
H A Dsyscall-restart2.c18 int fds[2]; local
20 if (pipe(fds) == -1) {
43 close(fds[1]);
44 ret = read(fds[0], &ch, 1);
52 close(fds[0]);
56 write(fds[1], "x", 1);
/external/chromium_org/ipc/
H A Dfile_descriptor_set_posix_unittest.cc86 static const int fds[] = {fd}; local
87 set->AddDescriptorsToOwn(fds, 1);
102 int fds[1]; local
103 fds[0] = 0;
104 set->PeekDescriptors(fds);
105 ASSERT_EQ(fds[0], kFDBase);
H A Dfile_descriptor_set_posix.cc140 std::vector<base::PlatformFile>* fds) {
144 fds->push_back((*i)->release());
139 ReleaseFDsToClose( std::vector<base::PlatformFile>* fds) argument
/external/compiler-rt/test/tsan/
H A Dfd_dup_norace.cc9 int fds[2]; variable
13 read(fds[0], &buf, 1);
14 close(fds[0]);
19 close(fds[1]);
24 fds[0] = open("/dev/random", O_RDONLY);
25 fds[1] = dup2(fds[0], 100);
H A Dfd_location.cc6 int fds[2]; variable
9 write(fds[1], "a", 1);
15 close(fds[0]);
16 close(fds[1]);
21 pipe(fds);
H A Dfd_pipe_race.cc6 int fds[2]; variable
9 write(fds[1], "a", 1);
15 close(fds[0]);
16 close(fds[1]);
21 pipe(fds);
H A Dfd_pipe_norace.cc6 int fds[2]; variable
11 write(fds[1], "a", 1);
17 while (read(fds[0], &buf, 1) != 1) {
24 pipe(fds);
H A Dfd_socketpair_norace.cc8 int fds[2]; variable
13 write(fds[1], "a", 1);
14 close(fds[1]);
20 while (read(fds[0], &buf, 1) != 1) {
23 close(fds[0]);
28 socketpair(AF_UNIX, SOCK_STREAM, 0, fds);
H A Dvfork.cc8 int fds[2]; variable
13 write(fds[1], "a", 1);
19 while (read(fds[0], &buf, 1) != 1) {
26 pipe(fds);
33 // Closing of fds must not affect parent process.
37 close(fds[0]);
38 close(fds[1]);
/external/chromium_org/content/renderer/pepper/
H A Dpepper_broker_unittest.cc43 int fds[2] = {-1, -1}; local
44 ASSERT_EQ(0, socketpair(AF_UNIX, SOCK_STREAM, 0, fds));
46 ASSERT_EQ(0, fcntl(fds[1], F_SETFL, O_NONBLOCK));
47 base::FileDescriptor file_descriptor(fds[1], true); // Auto close.
56 EXPECT_EQ(0, ::close(fds[0]));
/external/chromium_org/base/posix/
H A Dunix_domain_socket_linux_unittest.cc28 int fds[2]; local
29 ASSERT_EQ(0, socketpair(AF_UNIX, SOCK_SEQPACKET, 0, fds));
30 ScopedFD scoped_fd0(fds[0]);
31 ScopedFD scoped_fd1(fds[1]);
38 fds[1], static_cast<uint8_t*>(NULL), 0U, static_cast<int*>(NULL),
45 UnixDomainSocket::RecvMsg(fds[0], buffer, sizeof(buffer),
65 int fds[2]; local
66 ASSERT_EQ(0, socketpair(AF_UNIX, SOCK_SEQPACKET, 0, fds));
67 ScopedFD scoped_fd1(fds[1]);
68 ASSERT_EQ(0, IGNORE_EINTR(close(fds[
83 int fds[2]; local
110 int fds[2]; local
140 int fds[2]; local
[all...]
/external/chromium_org/content/browser/renderer_host/
H A Drender_sandbox_host_linux.cc28 int fds[2]; local
35 CHECK(socketpair(AF_UNIX, SOCK_SEQPACKET, 0, fds) == 0);
37 renderer_socket_ = fds[0];
42 const int browser_socket = fds[1];
/external/chromium_org/mojo/embedder/
H A Dplatform_channel_pair_posix.cc38 int fds[2]; local
40 PCHECK(socketpair(AF_UNIX, SOCK_STREAM, 0, fds) == 0);
41 PCHECK(fcntl(fds[0], F_SETFL, O_NONBLOCK) == 0);
42 PCHECK(fcntl(fds[1], F_SETFL, O_NONBLOCK) == 0);
51 fds[0], SOL_SOCKET, SO_NOSIGPIPE, &no_sigpipe, sizeof(no_sigpipe)) ==
55 fds[1], SOL_SOCKET, SO_NOSIGPIPE, &no_sigpipe, sizeof(no_sigpipe)) ==
59 server_handle_.reset(PlatformHandle(fds[0]));
61 client_handle_.reset(PlatformHandle(fds[1]));
H A Dplatform_channel_utils_posix.cc174 const int* fds = reinterpret_cast<int*>(CMSG_DATA(cmsg)); local
176 platform_handles->push_back(PlatformHandle(fds[i]));
/external/chromium_org/third_party/webrtc/base/
H A Dlinuxfdwalk_unittest.cc25 std::set<int> *fds = static_cast<std::set<int> *>(data); local
26 EXPECT_EQ(1U, fds->erase(fd));
30 std::set<int> *fds = static_cast<std::set<int> *>(data); local
31 EXPECT_TRUE(fds->insert(fd).second);
34 // Checks that the set of open fds is exactly the given list.
35 static void CheckOpenFdList(std::set<int> fds) { argument
36 EXPECT_EQ(0, fdwalk(&FdCheckVisitor, &fds));
37 EXPECT_EQ(0U, fds.size());
40 static void GetOpenFdList(std::set<int> *fds) { argument
41 fds
46 std::set<int> fds; local
[all...]
/external/e2fsprogs/lib/
H A Dfpopen.c42 int fds[2]; local
92 if (pipe(fds) < 0)
101 close(fds[1]);
102 dup2(fds[0], 0);
104 close(fds[0]);
105 dup2(fds[1], 1);
107 dup2(fds[1], 2);
113 return fdopen(do_stdin ? fds[1] : fds[0], mode);
/external/chromium_org/chrome/browser/
H A Dprocess_info_snapshot_mac_unittest.cc110 int fds[2]; local
111 PCHECK(pipe(fds) == 0);
113 fds_to_remap.push_back(std::make_pair(fds[1], 1));
127 PCHECK(IGNORE_EINTR(close(fds[1])) == 0);
132 PCHECK(HANDLE_EINTR(read(fds[0], buf, 1)) == 1);
147 PCHECK(IGNORE_EINTR(close(fds[0])) == 0);
/external/qemu/util/
H A Dcompatfd.c77 int fds[2]; local
85 if (pipe(fds) == -1) {
90 qemu_set_cloexec(fds[0]);
91 qemu_set_cloexec(fds[1]);
94 info->fd = fds[1];
98 return fds[0];
/external/chromium_org/components/nacl/loader/nonsfi/
H A Dnonsfi_sandbox_unittest.cc47 void DoPipe(base::ScopedFD* fds) { argument
50 fds[0].reset(tmp_fds[0]);
51 fds[1].reset(tmp_fds[1]);
54 void DoSocketpair(base::ScopedFD* fds) { argument
57 fds[0].reset(tmp_fds[0]);
58 fds[1].reset(tmp_fds[1]);
142 base::ScopedFD fds[2]; local
150 DoSocketpair(fds);
152 HANDLE_EINTR(sendmsg(fds[1].get(), &msg, 0)));
154 HANDLE_EINTR(recvmsg(fds[
256 int fds[2]; local
264 base::ScopedFD fds[2]; local
273 base::ScopedFD fds[2]; local
281 base::ScopedFD fds[2]; local
293 base::ScopedFD fds[2]; local
[all...]
/external/chromium_org/sandbox/linux/services/
H A Dunix_domain_socket_unittest.cc110 int fds[2]; local
111 CHECK_EQ(0, socketpair(AF_UNIX, SOCK_SEQPACKET, 0, fds));
112 base::ScopedFD recv_sock(fds[0]);
113 base::ScopedFD send_sock(fds[1]);
140 int fds[2]; local
141 CHECK_EQ(0, socketpair(AF_UNIX, SOCK_SEQPACKET, 0, fds));
142 base::ScopedFD recv_sock(fds[0]);
143 base::ScopedFD send_sock(fds[1]);
174 int fds[2]; local
175 CHECK_EQ(0, socketpair(AF_UNIX, SOCK_SEQPACKET, 0, fds));
240 int fds[2]; local
[all...]
/external/dhcpcd/
H A Dcontrol.c50 struct fd_list *fds = NULL; variable in typeref:struct:fd_list
57 for (l = fds; l != NULL; l = l->next) {
62 fds = l->next;
114 l->next = fds;
115 fds = l;
143 listen(fd, sizeof(fds)) == -1)
165 l = fds;

Completed in 1722 milliseconds

12345