Home
last modified time | relevance | path

Searched refs:ps (Results 1 – 13 of 13) sorted by relevance

/bionic/tests/
Duchar_test.cpp34 mbstate_t ps; in TEST() local
37 memset(&ps, 0, sizeof(ps)); in TEST()
38 EXPECT_EQ(static_cast<size_t>(-2), mbrtoc32(nullptr, "\xc2", 1, &ps)); in TEST()
39 EXPECT_EQ(static_cast<size_t>(-1), c32rtomb(out, 0x00a2, &ps)); in TEST()
44 memset(&ps, 0, sizeof(ps)); in TEST()
45 EXPECT_EQ(static_cast<size_t>(-2), mbrtoc32(nullptr, "\xc2", 1, &ps)); in TEST()
46 EXPECT_EQ(1U, c32rtomb(nullptr, 0x00a2, &ps)); in TEST()
47 EXPECT_TRUE(mbsinit(&ps)); in TEST()
49 memset(&ps, 0, sizeof(ps)); in TEST()
50 EXPECT_EQ(static_cast<size_t>(-2), mbrtoc32(nullptr, "\xf0\xa4", 1, &ps)); in TEST()
[all …]
Dspawn_test.cpp297 static __attribute__((unused)) void GetChildStat(posix_spawnattr_t* sa, ProcStat* ps) { in GetChildStat() argument
301 ASSERT_EQ(4, sscanf(content.c_str(), "%d (cat) %*c %d %d %d", &ps->pid, &ps->ppid, &ps->pgrp, in GetChildStat()
302 &ps->sid)); in GetChildStat()
304 ASSERT_EQ(getpid(), ps->ppid); in GetChildStat()
312 static void __attribute__((unused)) GetChildStatus(posix_spawnattr_t* sa, ProcStatus* ps) { in GetChildStatus() argument
319 if (sscanf(line.c_str(), "SigBlk: %" SCNx64, &ps->sigblk) == 1) saw_blk = true; in GetChildStatus()
320 if (sscanf(line.c_str(), "SigIgn: %" SCNx64, &ps->sigign) == 1) saw_ign = true; in GetChildStatus()
333 ProcStat ps = {}; in TEST() local
334 GetChildStat(&sa, &ps); in TEST()
335 ASSERT_EQ(parent_sid, ps.sid); in TEST()
[all …]
Dwchar_test.cpp98 mbstate_t ps; in TEST() local
101 memset(&ps, 0, sizeof(ps)); in TEST()
102 EXPECT_EQ(static_cast<size_t>(-2), mbrtowc(nullptr, "\xc2", 1, &ps)); in TEST()
103 EXPECT_EQ(static_cast<size_t>(-1), wcrtomb(out, 0x00a2, &ps)); in TEST()
108 memset(&ps, 0, sizeof(ps)); in TEST()
109 EXPECT_EQ(static_cast<size_t>(-2), mbrtowc(nullptr, "\xc2", 1, &ps)); in TEST()
110 EXPECT_EQ(1U, wcrtomb(nullptr, 0x00a2, &ps)); in TEST()
111 EXPECT_TRUE(mbsinit(&ps)); in TEST()
113 memset(&ps, 0, sizeof(ps)); in TEST()
114 EXPECT_EQ(static_cast<size_t>(-2), mbrtowc(nullptr, "\xf0\xa4", 1, &ps)); in TEST()
[all …]
/bionic/libc/private/
Dbionic_mbstate.h47 static inline __wur size_t mbstate_bytes_so_far(const mbstate_t* ps) { in mbstate_bytes_so_far() argument
49 (ps->__seq[2] != 0) ? 3 : in mbstate_bytes_so_far()
50 (ps->__seq[1] != 0) ? 2 : in mbstate_bytes_so_far()
51 (ps->__seq[0] != 0) ? 1 : 0; in mbstate_bytes_so_far()
54 static inline void mbstate_set_byte(mbstate_t* ps, int i, char byte) { in mbstate_set_byte() argument
55 ps->__seq[i] = static_cast<uint8_t>(byte); in mbstate_set_byte()
58 static inline __wur uint8_t mbstate_get_byte(const mbstate_t* ps, int n) { in mbstate_get_byte() argument
59 return ps->__seq[n]; in mbstate_get_byte()
62 static inline __wur size_t mbstate_reset_and_return_illegal(int _errno, mbstate_t* ps) { in mbstate_reset_and_return_illegal() argument
64 *(reinterpret_cast<uint32_t*>(ps->__seq)) = 0; in mbstate_reset_and_return_illegal()
[all …]
/bionic/libc/kernel/uapi/linux/
Dcoff.h24 #define COFF_SHORT_L(ps) ((short) (((unsigned short) ((unsigned char) ps[1]) << 8) | ((unsigned sho… argument
25ps) (((long) (((unsigned long) ((unsigned char) ps[3]) << 24) | ((unsigned long) ((unsigned char) argument
26 #define COFF_SHORT_H(ps) ((short) (((unsigned short) ((unsigned char) ps[0]) << 8) | ((unsigned sho… argument
27ps) (((long) (((unsigned long) ((unsigned char) ps[0]) << 24) | ((unsigned long) ((unsigned char) argument
/bionic/libc/bionic/
Dwchar.cpp56 int mbsinit(const mbstate_t* ps) { in mbsinit() argument
57 return (ps == nullptr || (*(reinterpret_cast<const uint32_t*>(ps->__seq)) == 0)); in mbsinit()
60 size_t mbrtowc(wchar_t* pwc, const char* s, size_t n, mbstate_t* ps) { in mbrtowc() argument
62 mbstate_t* state = (ps == nullptr) ? &__private_state : ps; in mbrtowc()
68 size_t mbsnrtowcs(wchar_t* dst, const char** src, size_t nmc, size_t len, mbstate_t* ps) { in mbsnrtowcs() argument
70 mbstate_t* state = (ps == nullptr) ? &__private_state : ps; in mbsnrtowcs()
135 size_t mbsrtowcs(wchar_t* dst, const char** src, size_t len, mbstate_t* ps) { in mbsrtowcs() argument
136 return mbsnrtowcs(dst, src, SIZE_MAX, len, ps); in mbsrtowcs()
139 size_t wcrtomb(char* s, wchar_t wc, mbstate_t* ps) { in wcrtomb() argument
141 mbstate_t* state = (ps == nullptr) ? &__private_state : ps; in wcrtomb()
[all …]
Dc32rtomb.cpp35 size_t c32rtomb(char* s, char32_t c32, mbstate_t* ps) { in c32rtomb() argument
37 mbstate_t* state = (ps == nullptr) ? &__private_state : ps; in c32rtomb()
Dc16rtomb.cpp43 size_t c16rtomb(char* s, char16_t c16, mbstate_t* ps) { in c16rtomb() argument
45 mbstate_t* state = (ps == nullptr) ? &__private_state : ps; in c16rtomb()
Dmbrtoc16.cpp61 size_t mbrtoc16(char16_t* pc16, const char* s, size_t n, mbstate_t* ps) { in mbrtoc16() argument
63 mbstate_t* state = (ps == nullptr) ? &__private_state : ps; in mbrtoc16()
Dmbrtoc32.cpp36 size_t mbrtoc32(char32_t* pc32, const char* s, size_t n, mbstate_t* ps) { in mbrtoc32() argument
38 mbstate_t* state = (ps == nullptr) ? &__private_state : ps; in mbrtoc32()
Diconv.cpp123 memset(&ps, 0, sizeof(ps)); in Convert()
142 mbstate_t ps; member
162 src_bytes_used = mbrtoc32(&wc, *src_buf, *src_bytes_left, &ps); in GetNext()
237 dst_bytes_used = c32rtomb(buf, wc, &ps); in Convert()
/bionic/libc/upstream-openbsd/lib/libc/locale/
Dmbrlen.c32 mbrlen(const char * __restrict s, size_t n, mbstate_t * __restrict ps) in mbrlen() argument
36 if (ps == NULL) in mbrlen()
37 ps = &mbs; in mbrlen()
38 return (mbrtowc(NULL, s, n, ps)); in mbrlen()
/bionic/libc/kernel/uapi/rdma/
Drdma_user_cm.h67 __u16 ps; member