Home
last modified time | relevance | path

Searched refs:rc (Results 1 – 25 of 39) sorted by relevance

12

/bionic/libc/bionic/
Dpipe.cpp36 int rc = __pipe2(pipefd, 0); in pipe() local
37 if (rc == 0) { in pipe()
41 return rc; in pipe()
45 int rc = __pipe2(pipefd, flags); in pipe2() local
46 if (rc == 0) { in pipe2()
50 return rc; in pipe2()
Dsys_statfs.cpp38 int rc = __fstatfs64(fd, sizeof(*result), result); in fstatfs() local
39 if (rc != 0) { in fstatfs()
40 return rc; in fstatfs()
48 int rc = __statfs64(path, sizeof(*result), result); in statfs() local
49 if (rc != 0) { in statfs()
50 return rc; in statfs()
Drecvmsg.cpp69 ssize_t rc = __recvmsg(__fd, __msg, __flags); in recvmsg() local
70 if (rc == -1) { in recvmsg()
74 return rc; in recvmsg()
79 int rc = __recvmmsg(__fd, __msgs, __msg_count, __flags, __timeout); in recvmmsg() local
80 if (rc == -1) { in recvmmsg()
83 for (int i = 0; i < rc; ++i) { in recvmmsg()
86 return rc; in recvmmsg()
Dfcntl.cpp51 int rc = __fcntl(fd, cmd, arg); in fcntl() local
54 int rc = __fcntl64(fd, cmd, arg); in fcntl() local
57 return FDTRACK_CREATE_NAME("F_DUPFD", rc); in fcntl()
59 return FDTRACK_CREATE_NAME("F_DUPFD_CLOEXEC", rc); in fcntl()
61 return rc; in fcntl()
Dsched_getaffinity.cpp36 int rc = __sched_getaffinity(pid, set_size, set); in sched_getaffinity() local
37 if (rc == -1) { in sched_getaffinity()
43 memset(reinterpret_cast<char*>(set) + rc, 0, set_size - rc); in sched_getaffinity()
Dsocketpair.cpp37 int rc = __socketpair(domain, type, protocol, sv); in socketpair() local
38 if (rc == 0) { in socketpair()
42 return rc; in socketpair()
Dposix_timers.cpp175 int rc = pthread_create(&timer->callback_thread, &thread_attributes, __timer_thread_start, timer); in timer_create() local
179 if (rc != 0) { in timer_create()
181 errno = rc; in timer_create()
190 rc = __timer_create(clock_id, &se, &timer->kernel_timer_id); in timer_create()
196 if (rc == -1) { in timer_create()
206 int rc = __timer_delete(to_kernel_timer_id(id)); in timer_delete() local
207 if (rc == -1) { in timer_delete()
Dsigprocmask.cpp49 int rc = sigprocmask64(how, new_set.ptr, old_set.ptr); in sigprocmask() local
50 if (rc == 0 && bionic_old_set != nullptr) { in sigprocmask()
53 return rc; in sigprocmask()
Ddl_iterate_phdr_static.cpp76 int rc = cb(&exe_info, sizeof(exe_info), data); in dl_iterate_phdr() local
77 if (rc != 0) { in dl_iterate_phdr()
78 return rc; in dl_iterate_phdr()
85 return rc; in dl_iterate_phdr()
Dsched_getcpu.cpp36 int rc = __getcpu(&cpu, nullptr, nullptr); in sched_getcpu() local
37 if (rc == -1) { in sched_getcpu()
Dlibgen.cpp162 int rc = __basename_r(path, buf, sizeof(__get_bionic_tls().basename_buf)); in basename() local
163 return (rc < 0) ? nullptr : buf; in basename()
168 int rc = __dirname_r(path, buf, sizeof(__get_bionic_tls().dirname_buf)); in dirname() local
169 return (rc < 0) ? nullptr : buf; in dirname()
Ddirent.cpp109 int rc = TEMP_FAILURE_RETRY(__getdents64(d->fd_, d->buff_, sizeof(d->buff_))); in __fill_DIR() local
110 if (rc <= 0) { in __fill_DIR()
113 d->available_bytes_ = rc; in __fill_DIR()
170 int rc = android_fdsan_close_with_tag(fd, __get_dir_tag(d)); in closedir() local
172 return rc; in closedir()
Dgetcwd.cpp59 int rc = __getcwd(buf, allocated_size); in getcwd() local
60 if (rc == -1) { in getcwd()
Dfdsan.cpp283 int rc = __close(fd); in android_fdsan_close_with_tag() local
285 if (expected_tag && rc == -1 && errno == EBADF) { in android_fdsan_close_with_tag()
288 return rc; in android_fdsan_close_with_tag()
387 int rc = android_fdsan_close_with_tag(fd, 0); in close() local
388 if (rc == -1 && errno == EINTR) { in close()
391 return rc; in close()
/bionic/tests/
Dsys_epoll_test.cpp66 int rc = epoll_pwait2(epoll_fd, events, 1, &ts, nullptr); in TEST() local
67 if (rc == -1 && errno == ENOSYS) GTEST_SKIP() << "no epoll_pwait2() in this kernel"; in TEST()
68 ASSERT_EQ(0, rc) << strerror(errno); in TEST()
96 int rc = epoll_pwait2(epoll_fd, events, 1, &ts, &ss2); in TEST() local
97 if (rc == -1 && errno == ENOSYS) GTEST_SKIP() << "no epoll_pwait2() in this kernel"; in TEST()
98 ASSERT_EQ(0, rc) << strerror(errno); in TEST()
114 int rc = epoll_pwait2_64(epoll_fd, events, 1, &ts, &ss2); in TEST() local
115 if (rc == -1 && errno == ENOSYS) GTEST_SKIP() << "no epoll_pwait2() in this kernel"; in TEST()
116 ASSERT_EQ(0, rc) << strerror(errno); in TEST()
Dlibgen_test.cpp46 int rc = basename_r(in, buf, buf_size); in TestBasename() local
47 ASSERT_EQ(expected_rc, rc) << in; in TestBasename()
48 if (rc != -1 && buf != nullptr) { in TestBasename()
57 int rc = dirname_r(in, buf, buf_size); in TestDirname() local
58 ASSERT_EQ(expected_rc, rc) << in; in TestDirname()
59 if (rc != -1 && buf != nullptr) { in TestDirname()
Dfdtrack_test.cpp237 int rc = pidfd_open(getpid(), 0);
238 if (rc == -1 && errno == ENOSYS) GTEST_SKIP() << "no pidfd_open() in this kernel";
239 ASSERT_NE(-1, rc) << strerror(errno);
240 rc;
251 int rc = pidfd_getfd(pidfd_self, STDIN_FILENO, 0);
252 if (rc == -1 && errno == ENOSYS) GTEST_SKIP() << "no pidfd_getfd() in this kernel";
253 ASSERT_NE(-1, rc) << strerror(errno);
259 rc;
343 pid_t rc = vfork();
344 ASSERT_NE(-1, rc);
[all …]
Dsys_sendfile_test.cpp35 ssize_t rc = sendfile(dst_file.fd, src_file.fd, &offset, count); in TEST() local
36 ASSERT_EQ(2, rc); in TEST()
54 ssize_t rc = sendfile64(dst_file.fd, src_file.fd, &offset, count); in TEST() local
55 ASSERT_EQ(2, rc); in TEST()
Dpidfd_test.cpp52 int rc = waitid(P_PIDFD, pidfd.get(), &siginfo, WEXITED); in TEST() local
53 if (rc == -1) { in TEST()
88 int rc = pidfd_send_signal(self.get(), 0, nullptr, 0); in TEST_F() local
89 if (rc == -1 && errno == ENOSYS) GTEST_SKIP() << "no pidfd_send_signal() in this kernel"; in TEST_F()
90 ASSERT_EQ(0, rc) << strerror(errno); in TEST_F()
Dfdsan_test.cpp209 pid_t rc = vfork(); in TEST_F() local
210 ASSERT_NE(-1, rc); in TEST_F()
212 if (rc == 0) { in TEST_F()
218 pid_t wait_result = waitpid(rc, &status, 0); in TEST_F()
219 ASSERT_EQ(wait_result, rc); in TEST_F()
Dsys_ptrace_test.cpp446 pid_t rc = TEMP_FAILURE_RETRY(waitpid(tracer, &result, 0)); in WaitForTracer() local
447 if (rc != tracer) { in WaitForTracer()
448 printf("waitpid returned %d (%s)\n", rc, strerror(errno)); in WaitForTracer()
473 pid_t rc = TEMP_FAILURE_RETRY(waitpid(worker, &result, WNOHANG)); in WaitForWorker() local
474 if (rc != 0) { in WaitForWorker()
481 rc = TEMP_FAILURE_RETRY(waitpid(worker, &result, 0)); in WaitForWorker()
482 if (rc != worker) { in WaitForWorker()
483 printf("waitpid for worker returned %d (%s)\n", rc, strerror(errno)); in WaitForWorker()
504 pid_t rc = TEMP_FAILURE_RETRY(waitpid(pid, &status, __WALL)); in wait_for_ptrace_stop() local
505 if (rc != pid) { in wait_for_ptrace_stop()
Dsys_stat_test.cpp111 int rc = statx(AT_FDCWD, "/proc/version", AT_STATX_SYNC_AS_STAT, STATX_ALL, &sx); in TEST() local
112 if (rc == -1 && errno == ENOSYS) GTEST_SKIP() << "no statx() in this kernel"; in TEST()
113 ASSERT_EQ(0, rc); in TEST()
/bionic/libc/arch-x86/bionic/
D__set_tls.cpp63 int rc = __set_thread_area(&tls_descriptor); in __set_tls() local
64 if (rc != -1) { in __set_tls()
72 return rc; in __set_tls()
/bionic/libc/malloc_debug/
DMapData.cpp95 ssize_t rc = process_vm_readv(getpid(), &dst_io, 1, &src_io, 1, 0); in Init() local
96 valid_ = rc == SELFMAG && IS_ELF(ehdr); in Init()
113 ssize_t rc = process_vm_readv(getpid(), &dst_io, 1, &src_io, 1, 0); in GetLoadBias() local
114 if (rc != sizeof(ehdr)) { in GetLoadBias()
126 rc = process_vm_readv(getpid(), &dst_io, 1, &src_io, 1, 0); in GetLoadBias()
127 if (rc != sizeof(phdr)) { in GetLoadBias()
/bionic/libc/system_properties/
Dcontexts_split.cpp153 int len, rc, items, entry_len = 0; in read_spec_entries() local
183 rc = read_spec_entry(spec_entry, &buf_p, &entry_len); in read_spec_entries()
184 if (rc < 0) { in read_spec_entries()
186 return rc; in read_spec_entries()

12