Home
last modified time | relevance | path

Searched refs:sa (Results 1 – 9 of 9) sorted by relevance

/bionic/tests/
Dspawn_test.cpp39 posix_spawnattr_t sa; in TEST() local
40 ASSERT_EQ(0, posix_spawnattr_init(&sa)); in TEST()
41 ASSERT_EQ(0, posix_spawnattr_destroy(&sa)); in TEST()
45 posix_spawnattr_t sa; in TEST() local
46 ASSERT_EQ(0, posix_spawnattr_init(&sa)); in TEST()
47 ASSERT_EQ(EINVAL, posix_spawnattr_setflags(&sa, ~0)); in TEST()
48 ASSERT_EQ(0, posix_spawnattr_destroy(&sa)); in TEST()
52 posix_spawnattr_t sa; in TEST() local
53 ASSERT_EQ(0, posix_spawnattr_init(&sa)); in TEST()
55 ASSERT_EQ(0, posix_spawnattr_setflags(&sa, POSIX_SPAWN_RESETIDS)); in TEST()
[all …]
Dsignal_test.cpp262 SigActionT sa = {}; in TestSigAction() local
263 sigaddset_fn(&sa.sa_mask, sig); in TestSigAction()
264 sa.sa_flags = SA_ONSTACK; in TestSigAction()
265 sa.sa_handler = no_op_signal_handler; in TestSigAction()
266 ASSERT_EQ(0, sigaction_fn(sig, &sa, nullptr)); in TestSigAction()
269 sa = {}; in TestSigAction()
270 ASSERT_EQ(0, sigaction_fn(sig, nullptr, &sa)); in TestSigAction()
271 ASSERT_TRUE(sa.sa_handler == no_op_signal_handler); in TestSigAction()
272 ASSERT_TRUE((void*) sa.sa_sigaction == (void*) sa.sa_handler); in TestSigAction()
273 ASSERT_EQ(static_cast<unsigned>(SA_ONSTACK), sa.sa_flags & ~sa_restorer); in TestSigAction()
[all …]
Dnetdb_test.cpp117 sockaddr* sa = reinterpret_cast<sockaddr*>(&ss); in TEST() local
125 ASSERT_EQ(0, getnameinfo(sa, too_much, tmp, sizeof(tmp), nullptr, 0, NI_NUMERICHOST)); in TEST()
127 ASSERT_EQ(0, getnameinfo(sa, just_right, tmp, sizeof(tmp), nullptr, 0, NI_NUMERICHOST)); in TEST()
129 ASSERT_EQ(EAI_FAMILY, getnameinfo(sa, too_little, tmp, sizeof(tmp), nullptr, 0, NI_NUMERICHOST)); in TEST()
136 ASSERT_EQ(0, getnameinfo(sa, too_much, tmp, sizeof(tmp), nullptr, 0, NI_NUMERICHOST)); in TEST()
138 ASSERT_EQ(0, getnameinfo(sa, just_right, tmp, sizeof(tmp), nullptr, 0, NI_NUMERICHOST)); in TEST()
140 ASSERT_EQ(EAI_FAMILY, getnameinfo(sa, too_little, tmp, sizeof(tmp), nullptr, 0, NI_NUMERICHOST)); in TEST()
/bionic/libc/dns/net/
Dgetnameinfo.c113 int getnameinfo(const struct sockaddr* sa, socklen_t salen, char* host, size_t hostlen, in getnameinfo() argument
116 return android_getnameinfofornet(sa, salen, host, hostlen, serv, servlen, flags, in getnameinfo()
120 int android_getnameinfofornet(const struct sockaddr* sa, socklen_t salen, char* host, in android_getnameinfofornet() argument
124 switch (sa->sa_family) { in android_getnameinfofornet()
127 return getnameinfo_inet(sa, salen, host, hostlen, in android_getnameinfofornet()
130 return getnameinfo_local(sa, salen, host, hostlen, in android_getnameinfofornet()
143 getnameinfo_local(const struct sockaddr *sa, socklen_t salen, in getnameinfo_local() argument
148 (const struct sockaddr_un *)(const void *)sa; in getnameinfo_local()
169 getnameinfo_inet(const struct sockaddr* sa, socklen_t salen, in getnameinfo_inet() argument
188 if (sa == NULL) in getnameinfo_inet()
[all …]
/bionic/libc/bionic/
Dsignal.cpp151 struct sigaction64 sa = { .sa_handler = SIG_IGN }; in sigignore() local
152 return sigaction64(sig, &sa, nullptr); in sigignore()
186 struct sigaction64 sa = { .sa_handler = handler, .sa_flags = flags }; in _signal() local
187 return (sigaction64(sig, &sa, &sa) == -1) ? SIG_ERR : sa.sa_handler; in _signal()
Dabort.cpp49 struct sigaction64 sa = { .sa_handler = SIG_DFL, .sa_flags = SA_RESTART }; in abort() local
50 sigaction64(SIGABRT, &sa, nullptr); in abort()
/bionic/libc/dns/resolv/
Dres_send.c156 struct sockaddr sa; member
194 if ( !bind( s, &u.sa, slen ) ) in random_bind()
205 return bind( s, &u.sa, slen ); in random_bind()
223 res_ourserver_p(const res_state statp, const struct sockaddr *sa) { in res_ourserver_p() argument
228 switch (sa->sa_family) { in res_ourserver_p()
230 inp = (const struct sockaddr_in *)(const void *)sa; in res_ourserver_p()
243 in6p = (const struct sockaddr_in6 *)(const void *)sa; in res_ourserver_p()
683 get_salen(sa) in get_salen() argument
684 const struct sockaddr *sa; in get_salen()
689 if (sa->sa_len)
[all …]
Dres_private.h20 res_ourserver_p(const res_state statp, const struct sockaddr *sa);
/bionic/libc/upstream-netbsd/lib/libc/isc/
Deventlib_p.h94 struct sockaddr sa; member
102 struct sockaddr sa; member