/bionic/tests/ |
D | sys_sendfile_test.cpp | 29 ASSERT_EQ(5, TEMP_FAILURE_RETRY(write(src_file.fd, "hello", 5))); in TEST() 42 ASSERT_EQ(2, TEMP_FAILURE_RETRY(read(dst_file.fd, &buf, 2))); in TEST() 48 ASSERT_EQ(5, TEMP_FAILURE_RETRY(write(src_file.fd, "hello", 5))); in TEST() 61 ASSERT_EQ(2, TEMP_FAILURE_RETRY(read(dst_file.fd, &buf, 2))); in TEST()
|
D | sys_ptrace_test.cpp | 56 TEMP_FAILURE_RETRY(waitpid(pid, &status, 0)); in ~ChildGuard() 174 ASSERT_EQ(child, TEMP_FAILURE_RETRY(waitpid(child, &status, __WALL))) << strerror(errno); in run_watchpoint_test() 183 ASSERT_EQ(child, TEMP_FAILURE_RETRY(waitpid(child, &status, __WALL))) << strerror(errno); in run_watchpoint_test() 341 ASSERT_EQ(child, TEMP_FAILURE_RETRY(waitpid(child, &status, __WALL))) << strerror(errno); in TEST() 350 ASSERT_EQ(child, TEMP_FAILURE_RETRY(waitpid(child, &status, __WALL))) << strerror(errno); in TEST() 395 TEMP_FAILURE_RETRY(read(worker_pipe_read.get(), &buf, sizeof(buf))); in PtraceResumptionTest() 401 TEMP_FAILURE_RETRY(read(worker_pipe_setup_read.get(), &buf, sizeof(buf))); in PtraceResumptionTest() 428 pid_t rc = TEMP_FAILURE_RETRY(waitpid(tracer, &result, 0)); in WaitForTracer() 455 pid_t rc = TEMP_FAILURE_RETRY(waitpid(worker, &result, WNOHANG)); in WaitForWorker() 463 rc = TEMP_FAILURE_RETRY(waitpid(worker, &result, 0)); in WaitForWorker() [all …]
|
D | utils.h | 168 ASSERT_EQ(pid, TEMP_FAILURE_RETRY(waitpid(pid, &status, 0))) << *error_msg; 239 while ((bytes_read = TEMP_FAILURE_RETRY(read(fds[0], buf, sizeof(buf)))) > 0) { in Run()
|
D | malloc_iterate_test.cpp | 218 pid_t wait_pid = TEMP_FAILURE_RETRY(waitpid(pid, nullptr, WNOHANG)); in TEST()
|
D | sched_test.cpp | 37 ASSERT_EQ(tid, TEMP_FAILURE_RETRY(waitpid(tid, &status, __WCLONE))); in TEST()
|
D | dlext_test.cpp | 113 extinfo.library_fd = TEMP_FAILURE_RETRY(open(lib_path.c_str(), O_RDONLY | O_CLOEXEC)); in TEST_F() 131 extinfo.library_fd = TEMP_FAILURE_RETRY(open(lib_path.c_str(), O_RDONLY | O_CLOEXEC)); in TEST_F() 157 extinfo.library_fd = TEMP_FAILURE_RETRY(open(lib_path.c_str(), O_RDONLY | O_CLOEXEC)); in TEST_F() 903 int tmpfd = TEMP_FAILURE_RETRY( in TEST() 957 ASSERT_TRUE(TEMP_FAILURE_RETRY(fstatfs(memfd, &st)) == 0) << strerror(errno); in TEST()
|
D | spawn_test.cpp | 491 ASSERT_EQ(spawned_pid, TEMP_FAILURE_RETRY(waitpid(spawned_pid, nullptr, 0))); in TEST()
|
/bionic/libc/bionic/ |
D | getentropy.cpp | 35 int fd = TEMP_FAILURE_RETRY(open("/dev/urandom", O_RDONLY | O_NOFOLLOW | O_CLOEXEC, 0)); in getentropy_urandom() 40 ssize_t count = TEMP_FAILURE_RETRY(read(fd, static_cast<char*>(buffer) + collected, in getentropy_urandom() 64 long count = TEMP_FAILURE_RETRY(getrandom(static_cast<char*>(buffer) + collected, in getentropy()
|
D | bionic_systrace.cpp | 72 TEMP_FAILURE_RETRY(write(trace_marker_fd, buf, len)); in bionic_trace_begin() 85 TEMP_FAILURE_RETRY(write(trace_marker_fd, "E|", 2)); in bionic_trace_end()
|
D | libc_init_common.cpp | 122 int dev_null = TEMP_FAILURE_RETRY(open("/dev/null", O_RDWR)); in __nullify_closed_stdio() 125 dev_null = TEMP_FAILURE_RETRY(open("/sys/fs/selinux/null", O_RDWR)); in __nullify_closed_stdio() 140 int status = TEMP_FAILURE_RETRY(fcntl(i, F_GETFL)); in __nullify_closed_stdio() 151 status = TEMP_FAILURE_RETRY(dup2(dev_null, i)); in __nullify_closed_stdio()
|
D | pthread_setname_np.cpp | 66 ssize_t n = TEMP_FAILURE_RETRY(read(fd, buf, buf_size)); in pthread_getname_np() 98 ssize_t n = TEMP_FAILURE_RETRY(write(fd, thread_name, thread_name_len)); in pthread_setname_np()
|
D | bionic_netlink.cpp | 77 return (TEMP_FAILURE_RETRY(send(fd_, &request, sizeof(request), 0)) == sizeof(request)); in SendRequest() 83 while ((bytes_read = TEMP_FAILURE_RETRY(recv(fd_, data_, size_, 0))) > 0) { in ReadResponses()
|
D | system_property_set.cpp | 69 if (TEMP_FAILURE_RETRY(connect(socket_, reinterpret_cast<sockaddr*>(&addr), alen)) == -1) { in PropertyServiceConnection() 85 int result = TEMP_FAILURE_RETRY(recv(socket_, value, sizeof(*value), MSG_WAITALL)); in RecvInt32() 192 const int num_bytes = TEMP_FAILURE_RETRY(send(s, msg, sizeof(prop_msg), 0)); in send_prop_msg() 204 const int poll_result = TEMP_FAILURE_RETRY(poll(pollfds, 1, 250 /* ms */)); in send_prop_msg()
|
D | netinet_in.cpp | 64 int rc = TEMP_FAILURE_RETRY(bind(sd, reinterpret_cast<sockaddr*>(sin), sizeof(*sin))); in bindresvport()
|
D | system.cpp | 69 pid_t pid = TEMP_FAILURE_RETRY(waitpid(child, &status, 0)); in system()
|
D | dirent.cpp | 109 int rc = TEMP_FAILURE_RETRY(__getdents64(d->fd_, d->buff_, sizeof(d->buff_))); in __fill_DIR()
|
/bionic/libc/tzcode/ |
D | bionic.cpp | 111 int fd = TEMP_FAILURE_RETRY(open(path, O_RDONLY | O_CLOEXEC)); in __bionic_open_tzdata_path() 117 ssize_t bytes_read = TEMP_FAILURE_RETRY(read(fd, &header, sizeof(header))); in __bionic_open_tzdata_path() 131 if (TEMP_FAILURE_RETRY(lseek(fd, ntohl(header.index_offset), SEEK_SET)) == -1) { in __bionic_open_tzdata_path() 157 if (TEMP_FAILURE_RETRY(read(fd, index, index_size)) != static_cast<ssize_t>(index_size)) { in __bionic_open_tzdata_path() 187 if (TEMP_FAILURE_RETRY(lseek(fd, specific_zone_offset, SEEK_SET)) == -1) { in __bionic_open_tzdata_path()
|
/bionic/libc/async_safe/ |
D | async_safe_log.cpp | 114 ssize_t bytes = TEMP_FAILURE_RETRY(write(fd_, data, len)); in Send() 452 int result = TEMP_FAILURE_RETRY(writev(STDERR_FILENO, vec, 4)); in write_stderr() 463 int log_fd = TEMP_FAILURE_RETRY(socket(PF_UNIX, SOCK_DGRAM | SOCK_CLOEXEC | SOCK_NONBLOCK, 0)); in open_log_socket() 476 if (TEMP_FAILURE_RETRY(connect(log_fd, &u.addr, sizeof(u.addrUn))) != 0) { in open_log_socket() 518 int result = TEMP_FAILURE_RETRY(writev(main_log_fd, vec, sizeof(vec) / sizeof(vec[0]))); in async_safe_write_log() 554 TEMP_FAILURE_RETRY(writev(2, iov, 2)); in async_safe_fatal_va_list()
|
/bionic/benchmarks/tests/ |
D | interface_test.cpp | 127 ssize_t bytes = TEMP_FAILURE_RETRY(read(fd_, buffer, sizeof(buffer) - 1)); in RunTest() 141 ASSERT_EQ(pid_, TEMP_FAILURE_RETRY(waitpid(pid_, &status, 0))) << "Test output:\n" << raw_output_; in RunTest()
|
/bionic/libc/malloc_debug/tests/ |
D | malloc_debug_system_tests.cpp | 86 if (TEMP_FAILURE_RETRY(poll(&read_fd, 1, 1)) > 0) { in Exec() 87 ssize_t bytes = TEMP_FAILURE_RETRY(read(fds[0], buffer.data(), sizeof(buffer) - 1)); in Exec()
|
/bionic/libc/stdio/ |
D | stdio.cpp | 431 if (TEMP_FAILURE_RETRY(wait4(pid, &status, 0, nullptr)) != -1) { in __FILE_close() 532 return TEMP_FAILURE_RETRY(read(fp->_file, buf, n)); in __sread() 537 return TEMP_FAILURE_RETRY(write(fp->_file, buf, n)); in __swrite() 542 return TEMP_FAILURE_RETRY(lseek(fp->_file, offset, whence)); in __sseek() 547 return TEMP_FAILURE_RETRY(lseek64(fp->_file, offset, whence)); in __sseek64()
|
/bionic/linker/ |
D | linker_phdr.cpp | 189 ssize_t rc = TEMP_FAILURE_RETRY(pread64(fd_, &header_, sizeof(header_), file_offset_)); in ReadElfHeader() 855 ssize_t written = TEMP_FAILURE_RETRY(write(fd, reinterpret_cast<void*>(seg_page_start), size)); in phdr_table_serialize_gnu_relro() 893 if (TEMP_FAILURE_RETRY(fstat(fd, &file_stat)) != 0) { in phdr_table_map_gnu_relro()
|
D | linker_main.cpp | 216 if (TEMP_FAILURE_RETRY(stat("/proc/self/exe", &result.file_stat)) != 0) { in get_executable_info() 276 if (TEMP_FAILURE_RETRY(fstat(fd.get(), &result.file_stat)) == -1) { in load_executable()
|
D | linker.cpp | 977 int fd = TEMP_FAILURE_RETRY(open(zip_path, O_RDONLY | O_CLOEXEC)); in get_or_open() 1028 int fd = TEMP_FAILURE_RETRY(open(zip_path, O_RDONLY | O_CLOEXEC)); in open_library_in_zipfile() 1088 fd = TEMP_FAILURE_RETRY(open(path, O_RDONLY | O_CLOEXEC)); in open_library_at_path() 1138 fd = TEMP_FAILURE_RETRY(open(name, O_RDONLY | O_CLOEXEC)); in open_library() 1281 if (TEMP_FAILURE_RETRY(fstat(task->get_fd(), &file_stat)) != 0) { in load_library() 1311 if (TEMP_FAILURE_RETRY(fstatfs(task->get_fd(), &fs_stat)) != 0) { in load_library()
|
/bionic/libc/include/ |
D | unistd.h | 308 #define TEMP_FAILURE_RETRY(exp) ({ \ macro
|