Searched refs:len (Results 1 - 25 of 736) sorted by relevance

1234567891011>>

/system/bt/btif/include/
H A Dbtif_sock_util.h32 int sock_send_fd(int sock_fd, const uint8_t* buffer, int len, int send_fd);
33 int sock_send_all(int sock_fd, const uint8_t* buf, int len);
34 int sock_recv_all(int sock_fd, uint8_t* buf, int len);
/system/core/toolbox/upstream-netbsd/lib/libc/string/
H A Dswab.c48 swab(const void * __restrict from, void * __restrict to, ssize_t len) argument
54 if (len <= 1)
60 len /= 2;
65 if (__predict_false(len == 1)) {
71 while ((--len % 8) != 0)
73 len /= 8;
74 if (len == 0)
76 while (len-- != 0) {
/system/core/toolbox/upstream-netbsd/usr.bin/grep/
H A Dfastgrep.c63 fg->len = strlen(pat);
72 fg->qsBc[i] = fg->len;
73 for (i = 1; i < fg->len; i++)
74 fg->qsBc[fg->pattern[i]] = fg->len - i;
91 fg->len = strlen(pat);
98 if (fg->len > 0 && pat[fg->len - 1] == '$') {
100 fg->len--;
106 fg->len--;
110 if (fg->len >
205 grep_search(fastgrep_t *fg, const unsigned char *data, size_t len, regmatch_t *pmatch) argument
281 grep_cmp(const unsigned char *pat, const unsigned char *data, size_t len) argument
326 grep_revstr(unsigned char *str, int len) argument
[all...]
/system/bt/test/suite/rfcomm/
H A Drfcomm_unittest.cc34 size_t len = 0; local
44 len = read(fd, &channel, sizeof(channel));
45 EXPECT_TRUE(len == sizeof(channel))
46 << "Channel not read from RFCOMM socket. Bytes read: " << len;
47 len = read(fd, &signal, sizeof(signal));
48 EXPECT_TRUE(len == sizeof(signal))
49 << "Connection signal not read from RFCOMM socket. Bytes read: " << len;
57 len = write(fd, HANDSHAKE_COMMAND, sizeof(HANDSHAKE_COMMAND));
58 EXPECT_TRUE(len == sizeof(HANDSHAKE_COMMAND))
59 << "Unable to send HFP handshake. Bytes written: " << len;
75 size_t len = 0; local
[all...]
/system/bt/osi/src/
H A Dproperties.cc34 int len = 0; local
35 if (!default_value) return len;
37 len = strlen(default_value);
38 if (len >= PROPERTY_VALUE_MAX) len = PROPERTY_VALUE_MAX - 1;
40 memcpy(value, default_value, len);
41 value[len] = '\0';
42 return len;
/system/core/liblog/
H A Duio.c30 int len = vecs->iov_len; local
32 while (len > 0) {
33 int ret = read(fd, buf, len);
42 len -= ret;
54 int len = vecs->iov_len; local
56 while (len > 0) {
57 int ret = write(fd, buf, len);
66 len -= ret;
H A Dfake_writer.c79 int logFd, len; local
85 len = 0;
87 len += vec[i].iov_len;
90 if (len > LOGGER_ENTRY_MAX_PAYLOAD) {
91 len = LOGGER_ENTRY_MAX_PAYLOAD;
98 } else if (ret > len) {
99 ret = len;
/system/core/libsparse/
H A Doutput_file.h28 struct output_file *output_file_open_fd(int fd, unsigned int block_size, int64_t len,
31 void *priv, unsigned int block_size, int64_t len, int gz, int sparse,
33 int write_data_chunk(struct output_file *out, unsigned int len, void *data);
34 int write_fill_chunk(struct output_file *out, unsigned int len,
36 int write_file_chunk(struct output_file *out, unsigned int len,
38 int write_fd_chunk(struct output_file *out, unsigned int len,
40 int write_skip_chunk(struct output_file *out, int64_t len);
43 int read_all(int fd, void *buf, size_t len);
/system/core/qemu_pipe/include/
H A Dqemu_pipe.h48 // Send a framed message |buff| of |len| bytes through the |fd| descriptor.
51 int qemu_pipe_frame_send(int fd, const void* buff, size_t len);
53 // Read a frame message from |fd|, and store it into |buff| of |len| bytes.
54 // If the framed message is larger than |len|, then this returns -1 and the
58 int qemu_pipe_frame_recv(int fd, void* buff, size_t len);
/system/core/libcutils/
H A Dstrdup16to8.cpp29 extern size_t strnlen16to8(const char16_t* utf16Str, size_t len) argument
34 * potentially be as big as 3*len, which will overflow
35 * for len > SIZE_MAX/3.
43 * dst = malloc(strnlen16to8(utf16,len)+1)
55 /* Fast path for the usual case where 3*len is < SIZE_MAX-1.
57 if (len < (SIZE_MAX-1)/3) {
58 while (len != 0) {
59 len--;
73 while (len != 0) {
74 len
109 strncpy16to8(char* utf8Str, const char16_t* utf16Str, size_t len) argument
152 size_t len = strnlen16to8(s, n); local
[all...]
H A Dfs_config.cpp214 static size_t strip(const char* path, size_t len, const char suffix[]) { argument
215 if (len < strlen(suffix)) return len;
216 if (strncmp(path + len - strlen(suffix), suffix, strlen(suffix))) return len;
217 return len - strlen(suffix);
228 size_t len = strlen(target_out_path); local
229 len = strip(target_out_path, len, "/");
230 len
244 is_partition(const char* path, size_t len) argument
254 prefix_cmp(bool partial, const char* prefix, size_t len, const char* path, size_t plen) argument
261 fs_config_cmp(bool partial, const char* prefix, size_t len, const char* path, size_t plen) argument
309 ssize_t len, remainder = host_len - sizeof(header); local
357 size_t len = ALIGN(sizeof(*p) + strlen(pc->prefix) + 1, sizeof(uint64_t)); local
[all...]
H A Dproperties.cpp41 int len = property_get(key, buf, ""); local
42 if (len == 1) {
49 } else if (len > 1) {
71 int len = property_get(key, buf, ""); local
72 if (len > 0) {
115 int len = __system_property_get(key, value); local
116 if (len > 0) {
117 return len;
120 len = strnlen(default_value, PROPERTY_VALUE_MAX - 1);
121 memcpy(value, default_value, len);
[all...]
/system/core/logd/
H A DLogKlog.cpp52 static char* is_prio(char* s, ssize_t len) { argument
53 if ((len <= 0) || !isdigit(*s++)) return nullptr;
54 --len;
55 static const size_t max_prio_len = (len < 4) ? len : 4;
65 static char* is_timestamp(char* s, ssize_t len) { argument
66 while ((len > 0) && (*s == ' ')) {
68 --len;
70 if ((len <= 0) || !isdigit(*s++)) return nullptr;
71 --len;
99 log_strntok_r(char* s, ssize_t& len, char*& last, ssize_t& sublen) argument
230 ssize_t len = 0; local
266 calculateCorrection(const log_time& monotonic, const char* real_string, ssize_t len) argument
296 sniffTime(log_time& now, const char*& buf, ssize_t len, bool reverse) argument
368 sniffPid(const char*& buf, ssize_t len) argument
415 parseKernelPrio(const char*& buf, ssize_t len) argument
436 synchronize(const char* buf, ssize_t len) argument
504 strnrchr(const char* s, ssize_t len, char c) argument
547 log(const char* buf, ssize_t len) argument
[all...]
H A DLogKlog.h44 int log(const char* buf, ssize_t len);
45 void synchronize(const char* buf, ssize_t len);
58 void sniffTime(log_time& now, const char*& buf, ssize_t len, bool reverse);
59 pid_t sniffPid(const char*& buf, ssize_t len);
61 ssize_t len);
/system/bt/osi/test/
H A Dallocator_test.cc30 size_t len = strlen(str); local
33 // len == 0
38 // len == strlen(str)
39 copy_str = osi_strndup(str, len);
43 // len < strlen(str)
44 copy_str = osi_strndup(str, len - 5);
48 // len > strlen(str)
49 copy_str = osi_strndup(str, len + 5);
/system/core/adb/
H A Dadb_io.cpp52 unsigned long len = strtoul(buf, 0, 16); local
53 s->resize(len, '\0');
54 if (!ReadFdExactly(fd, &(*s)[0], len)) {
70 bool ReadFdExactly(int fd, void* buf, size_t len) { argument
73 size_t len0 = len;
75 D("readx: fd=%d wanted=%zu", fd, len);
76 while (len > 0) {
77 int r = adb_read(fd, p, len);
79 len -= r;
91 VLOG(RWX) << "readx: fd=" << fd << " wanted=" << len0 << " got=" << (len0 - len)
97 WriteFdExactly(int fd, const void* buf, size_t len) argument
102 << " " << dump_hex(reinterpret_cast<const unsigned char*>(buf), len); local
[all...]
/system/extras/ext4_utils/include/ext4_utils/
H A Dwipe.h35 int wipe_block_device(int fd, s64 len);
/system/extras/ext4_utils/
H A Dwipe.c36 int wipe_block_device(int fd, s64 len) argument
47 range[1] = len;
51 range[1] = len;
71 int wipe_block_device(int fd, s64 len) argument
/system/core/fastboot/
H A Dtransport.h29 // Reads |len| bytes into |data|. Returns the number of bytes actually
31 virtual ssize_t Read(void* data, size_t len) = 0;
33 // Writes |len| bytes from |data|. Returns the number of bytes actually
35 virtual ssize_t Write(const void* data, size_t len) = 0;
/system/security/keystore/include/keystore/
H A DKeystoreArg.h28 KeystoreArg(const void* data, size_t len) : mData(data), mSize(len) {} argument
/system/timezone/
H A Dtzdatautil.py26 if len(matching_files) == 0:
28 elif len(matching_files) == 1:
/system/bt/packet/avrcp/
H A Dset_browsed_player.cc36 size_t len = BrowsePacket::kMinSize(); local
37 len += 1; // Status
40 if (status_ != Status::NO_ERROR) return len;
42 len += 2; // UID Counter
43 len += 4; // Number of items in folder
44 len += 2; // UTF-8 Character Set
45 len += 1; // Folder Depth
49 len += 2; // Folder Name Size;
50 len += folder_name_.size(); // Folder Name
53 return len;
[all...]
/system/bt/stack/include/
H A Dadvertise_data_parser.h52 uint8_t len = ad[position]; local
59 if (len == 0) {
64 if (position + len >= ad_len) {
68 position += len + 1;
80 uint8_t len = ad[position]; local
85 if (len == 0) {
94 if (position + len >= ad_len) {
100 position += len + 1;
115 uint8_t len = ad[position]; local
117 if (len
[all...]
/system/core/libsparse/include/sparse/
H A Dsparse.h33 * @len - size of the expanded sparse file.
42 struct sparse_file *sparse_file_new(unsigned int block_size, int64_t len);
59 * @len - length of the data block
63 * [block * block_size : block * block_size + len) must not already be used in
64 * the sparse file. If len is not a multiple of the block size the data
73 void *data, unsigned int len, unsigned int block);
80 * @len - length of the fill block
84 * The region [block * block_size : block * block_size + len) must not already
85 * be used in the sparse file. If len is not a multiple of the block size the
91 uint32_t fill_val, unsigned int len, unsigne
[all...]
/system/extras/ioshark/
H A Dioshark_bench_mmap.c48 size_t len; member in struct:mmap_io_ent_tab_s
70 mio->table[mio->num_entries].len =
72 total_len -= mio->table[mio->num_entries].len;
73 offset += mio->table[mio->num_entries].len;
91 if (mio->table[i].len > 0)
97 iolength = MIN(mio->table[i].len, iolength);
100 mio->table[i].len -= iolength;
106 mmap_do_io(void *db_node, int prot, off_t offset, size_t len, argument
115 p = get_buf(bufp, buflen, len, 0);
117 p, len, offse
171 size_t len = file_op->mmap_len; local
[all...]

Completed in 364 milliseconds

1234567891011>>