/external/llvm-project/clang-tools-extra/test/clang-tidy/checkers/ |
D | android-cloexec-pipe2.cpp | 15 extern "C" int pipe2(int pipefd[2], int flags); 18 int pipefd[2]; in warning() local 19 pipe2(pipefd, O_NONBLOCK); in warning() 22 TEMP_FAILURE_RETRY(pipe2(pipefd, O_NONBLOCK)); in warning() 28 int pipefd[2]; in warningInMacroArugment() local 29 pipe2(pipefd, 3); in warningInMacroArugment() 32 TEMP_FAILURE_RETRY(pipe2(pipefd, 3)); in warningInMacroArugment() 37 pipe2(pipefd, flag); in warningInMacroArugment() 38 TEMP_FAILURE_RETRY(pipe2(pipefd, flag)); in warningInMacroArugment() 42 int pipe2(int pipefd[2], int flags); [all …]
|
D | android-cloexec-pipe.cpp | 3 extern "C" int pipe(int pipefd[2]); 6 int pipefd[2]; in warning() local 7 pipe(pipefd); in warning() 13 int pipe(int pipefd[2]); 15 int pipefd[2]; in noWarningInNamespace() local 16 pipe(pipefd); in noWarningInNamespace() 22 int pipe(int pipefd[2]); 24 int pipefd[2]; in noWarningForMemberFunction() local 25 pipe(pipefd); in noWarningForMemberFunction()
|
/external/ltp/testcases/kernel/syscalls/sendmsg/ |
D | sendmsg02.c | 63 static void client(int id, int pipefd[]) in client() argument 72 close(pipefd[0]); in client() 93 write(pipefd[1], &fd, 1); in client() 98 close(pipefd[1]); in client() 101 static void server(int id, int pipefd[]) in server() argument 106 close(pipefd[1]); in server() 116 read(pipefd[0], &fd, 1); in server() 120 close(pipefd[0]); in server() 125 int i, status, pipefd[2]; in reproduce() local 141 if (pipe(pipefd) < 0) { in reproduce() [all …]
|
/external/strace/tests-m32/ |
D | ioctl_nsfs.c | 98 int *pipefd = (int *) arg; in child() local 99 close(pipefd[1]); in child() 101 if (read(pipefd[0], &pipefd[1], 1)) in child() 116 int pipefd[2]; in test_user_namespace() local 119 if (pipe(pipefd)) in test_user_namespace() 123 CLONE_NEWUSER | CLONE_UNTRACED | SIGCHLD, pipefd); in test_user_namespace() 128 close(pipefd[0]); in test_user_namespace() 130 close(pipefd[1]); in test_user_namespace()
|
D | pipe_maxfd.c | 46 pipe_maxfd(int pipefd[2]) in pipe_maxfd() 58 if (pipe(pipefd)) in pipe_maxfd() 64 move_fd(&pipefd[1], &max_fd); in pipe_maxfd() 66 move_fd(&pipefd[0], &max_fd); in pipe_maxfd()
|
/external/strace/tests/ |
D | ioctl_nsfs.c | 98 int *pipefd = (int *) arg; in child() local 99 close(pipefd[1]); in child() 101 if (read(pipefd[0], &pipefd[1], 1)) in child() 116 int pipefd[2]; in test_user_namespace() local 119 if (pipe(pipefd)) in test_user_namespace() 123 CLONE_NEWUSER | CLONE_UNTRACED | SIGCHLD, pipefd); in test_user_namespace() 128 close(pipefd[0]); in test_user_namespace() 130 close(pipefd[1]); in test_user_namespace()
|
D | pipe_maxfd.c | 46 pipe_maxfd(int pipefd[2]) in pipe_maxfd() 58 if (pipe(pipefd)) in pipe_maxfd() 64 move_fd(&pipefd[1], &max_fd); in pipe_maxfd() 66 move_fd(&pipefd[0], &max_fd); in pipe_maxfd()
|
/external/strace/tests-mx32/ |
D | ioctl_nsfs.c | 98 int *pipefd = (int *) arg; in child() local 99 close(pipefd[1]); in child() 101 if (read(pipefd[0], &pipefd[1], 1)) in child() 116 int pipefd[2]; in test_user_namespace() local 119 if (pipe(pipefd)) in test_user_namespace() 123 CLONE_NEWUSER | CLONE_UNTRACED | SIGCHLD, pipefd); in test_user_namespace() 128 close(pipefd[0]); in test_user_namespace() 130 close(pipefd[1]); in test_user_namespace()
|
D | pipe_maxfd.c | 46 pipe_maxfd(int pipefd[2]) in pipe_maxfd() 58 if (pipe(pipefd)) in pipe_maxfd() 64 move_fd(&pipefd[1], &max_fd); in pipe_maxfd() 66 move_fd(&pipefd[0], &max_fd); in pipe_maxfd()
|
/external/ltp/testcases/kernel/containers/pidns/ |
D | pidns12.c | 50 int pipefd[2]; variable 85 close(pipefd[0]); in child_fn() 97 if (write(pipefd[1], "c:go\0", 5) != 5) { in child_fn() 104 close(pipefd[1]); in child_fn() 132 if (pipe(pipefd) == -1) { in main() 142 close(pipefd[1]); in main() 145 read(pipefd[0], buf, 5); in main() 164 close(pipefd[0]); in main()
|
/external/libusb/libusb/os/ |
D | events_posix.c | 37 #define EVENT_READ_FD(e) ((e)->pipefd[0]) 38 #define EVENT_WRITE_FD(e) ((e)->pipefd[1]) 59 int ret = pipe2(event->pipefd, O_CLOEXEC); in usbi_create_event() 61 int ret = pipe(event->pipefd); in usbi_create_event() 70 ret = fcntl(event->pipefd[0], F_GETFD); in usbi_create_event() 75 ret = fcntl(event->pipefd[0], F_SETFD, ret | FD_CLOEXEC); in usbi_create_event() 81 ret = fcntl(event->pipefd[1], F_GETFD); in usbi_create_event() 86 ret = fcntl(event->pipefd[1], F_SETFD, ret | FD_CLOEXEC); in usbi_create_event() 93 ret = fcntl(event->pipefd[1], F_GETFL); in usbi_create_event() 98 ret = fcntl(event->pipefd[1], F_SETFL, ret | O_NONBLOCK); in usbi_create_event() [all …]
|
/external/mtools/ |
D | expand.c | 27 int pipefd[2]; in safePopenOut() local 32 if(pipe(pipefd)) { in safePopenOut() 39 close(pipefd[0]); in safePopenOut() 43 if(dup(pipefd[1]) < 0) { in safePopenOut() 47 close(pipefd[1]); in safePopenOut() 51 close(pipefd[1]); in safePopenOut() 54 last=read(pipefd[0], output, len); in safePopenOut()
|
/external/oss-fuzz/projects/ibmswtpm2/ |
D | fuzzer.cc | 27 int pipefd[2]; in LLVMFuzzerTestOneInput() local 33 if (pipe(pipefd) == -1) { in LLVMFuzzerTestOneInput() 38 if (write(pipefd[1], Data, Size) != (ssize_t)Size) { in LLVMFuzzerTestOneInput() 43 close(pipefd[1]); in LLVMFuzzerTestOneInput() 73 TpmServer(pipefd[0]); in LLVMFuzzerTestOneInput() 75 close(pipefd[0]); in LLVMFuzzerTestOneInput()
|
/external/ltp/testcases/kernel/syscalls/pipe/ |
D | pipe09.c | 80 int pipefd[2]; /* fds for pipe read/write */ in main() local 94 TEST(pipe(pipefd)); in main() 106 if (close(pipefd[0]) != 0) { in main() 113 if (write(pipefd[1], "A", 1) != 1) { in main() 133 if (close(pipefd[0]) != 0) { in main() 139 if (write(pipefd[1], "B", 1) != 1) { in main() 155 if (close(pipefd[1]) != 0) { in main() 160 while ((red = do_read(pipefd[0], rebuf, 100)) > 0) { in main()
|
D | pipe08.c | 67 int pipefd[2]; /* fds for pipe read/write */ in main() local 81 TEST(pipe(pipefd)); in main() 88 if ((close_stat = close(pipefd[0])) == -1) { in main() 100 written = write(pipefd[1], wrbuf, length); in main()
|
/external/wayland/tests/ |
D | test-runner.c | 235 int pipefd[2]; in is_debugger_attached() local 237 if (pipe(pipefd) == -1) { in is_debugger_attached() 245 close(pipefd[0]); in is_debugger_attached() 246 close(pipefd[1]); in is_debugger_attached() 253 close(pipefd[1]); /* Close unused write end */ in is_debugger_attached() 254 read(pipefd[0], &buf, 1); in is_debugger_attached() 255 close(pipefd[0]); in is_debugger_attached() 266 close(pipefd[0]); in is_debugger_attached() 277 write(pipefd[1], "-", 1); in is_debugger_attached() 280 write(pipefd[1], "+", 1); in is_debugger_attached() [all …]
|
/external/llvm-project/libc/utils/testutils/ |
D | FDReaderUnix.cpp | 19 if (::pipe(pipefd)) { in FDReader() 26 ::close(pipefd[0]); in ~FDReader() 27 ::close(pipefd[1]); in ~FDReader() 32 ::close(pipefd[1]); in matchWritten() 40 for (int BytesRead; (BytesRead = ::read(pipefd[0], Buffer, ChunkSize));) { in matchWritten()
|
/external/grpc-grpc/src/core/lib/iomgr/ |
D | wakeup_fd_pipe.cc | 37 int pipefd[2]; in pipe_init() local 38 int r = pipe(pipefd); in pipe_init() 44 err = grpc_set_socket_nonblocking(pipefd[0], 1); in pipe_init() 46 err = grpc_set_socket_nonblocking(pipefd[1], 1); in pipe_init() 48 fd_info->read_fd = pipefd[0]; in pipe_init() 49 fd_info->write_fd = pipefd[1]; in pipe_init()
|
/external/rust/crates/grpcio-sys/grpc/src/core/lib/iomgr/ |
D | wakeup_fd_pipe.cc | 37 int pipefd[2]; in pipe_init() local 38 int r = pipe(pipefd); in pipe_init() 44 err = grpc_set_socket_nonblocking(pipefd[0], 1); in pipe_init() 46 err = grpc_set_socket_nonblocking(pipefd[1], 1); in pipe_init() 48 fd_info->read_fd = pipefd[0]; in pipe_init() 49 fd_info->write_fd = pipefd[1]; in pipe_init()
|
/external/ltp/testcases/kernel/syscalls/setrlimit/ |
D | setrlimit01.c | 126 int pipefd[2]; in test2() local 128 SAFE_PIPE(NULL, pipefd); in test2() 142 close(pipefd[0]); /* close unused read end */ in test2() 154 if (write(pipefd[1], &bytes, sizeof(bytes)) in test2() 158 close(pipefd[1]); /* EOF */ in test2() 179 close(pipefd[1]); /* close unused write end */ in test2() 180 if (read(pipefd[0], &bytes, sizeof(bytes)) < sizeof(bytes)) in test2() 183 close(pipefd[0]); in test2()
|
/external/google-breakpad/src/client/linux/minidump_writer/ |
D | linux_dumper_unittest_helper.cc | 59 int pipefd = *static_cast<int *>(data); in thread_function() local 64 if (write(pipefd, &byte, sizeof(byte)) != sizeof(byte)) { in thread_function() 80 int pipefd = atoi(argv[1]); in main() local 91 pthread_create(&threads[i], &thread_attributes, &thread_function, &pipefd); in main() 93 thread_function(&pipefd); in main()
|
/external/adhd/cras/src/tools/cras_router/ |
D | cras_router.c | 26 static int pipefd[2]; variable 32 return write(pipefd[1], "1", 1); in terminate_stream_loop() 119 if (pipe(pipefd) == -1) { in run_file_io_stream() 159 FD_SET(pipefd[0], &poll_set); in run_file_io_stream() 160 pselect(pipefd[0] + 1, &poll_set, NULL, NULL, NULL, NULL); in run_file_io_stream() 166 close(pipefd[0]); in run_file_io_stream() 167 close(pipefd[1]); in run_file_io_stream()
|
/external/linux-kselftest/tools/testing/selftests/kcmp/ |
D | kcmp_test.c | 36 int pipefd[2]; in main() local 50 if (pipe(pipefd)) { in main() 64 if (epoll_ctl(epollfd, EPOLL_CTL_ADD, pipefd[0], &ev)) { in main() 69 fddup = dup2(pipefd[1], duped_num); in main() 143 ret = sys_kcmp(pid1, pid1, KCMP_EPOLL_TFD, pipefd[1], in main()
|
/external/ltp/testcases/kernel/syscalls/write/ |
D | write05.c | 32 static int pipefd[2]; variable 42 {&pipefd[1], &buf, sizeof(buf), EPIPE}, 88 SAFE_PIPE(pipefd); in setup() 89 SAFE_CLOSE(pipefd[0]); in setup()
|
/external/dnsmasq/src/ |
D | helper.c | 54 int i, pipefd[2]; in create_helper() local 59 if (pipe(pipefd) == -1 || !fix_fd(pipefd[1]) || (pid = fork()) == -1) { in create_helper() 65 close(pipefd[0]); /* close reader side */ in create_helper() 66 return pipefd[1]; in create_helper() 96 max_fd != pipefd[0] && max_fd != event_fd) in create_helper() 107 if (!read_write(pipefd[0], (unsigned char*) &data, sizeof(data), 1)) _exit(0); in create_helper() 128 if (!read_write(pipefd[0], buf, data.clid_len, 1)) continue; in create_helper() 141 if (!read_write(pipefd[0], buf, in create_helper() 238 close(pipefd[0]); in create_helper()
|