/bionic/libc/bionic/ |
H A D | android_set_abort_message.cpp | 39 size_t size; member in struct:abort_msg_t 59 size_t size = sizeof(abort_msg_t) + strlen(msg) + 1; local 60 void* map = mmap(nullptr, size, PROT_READ | PROT_WRITE, MAP_ANON | MAP_PRIVATE, -1, 0); 66 new_abort_message->size = size;
|
H A D | dl_iterate_phdr_static.cpp | 38 int dl_iterate_phdr(int (*cb)(struct dl_phdr_info* info, size_t size, void* data), void* data) { argument
|
H A D | epoll_create.cpp | 32 int epoll_create(int size) { argument 33 if (size <= 0) {
|
H A D | fgetxattr.cpp | 38 ssize_t fgetxattr(int fd, const char *name, void *value, size_t size) { argument 40 ssize_t result = ___fgetxattr(fd, name, value, size); 58 return getxattr(buf, name, value, size);
|
H A D | flistxattr.cpp | 38 ssize_t flistxattr(int fd, char *list, size_t size) { argument 40 ssize_t result = ___flistxattr(fd, list, size); 58 return listxattr(buf, list, size);
|
H A D | fortify.cpp | 101 __fortify_fatal("fgets: buffer size %d < 0", supplied_size); 107 size_t __fread_chk(void* __restrict buf, size_t size, size_t count, argument 110 if (__predict_false(__size_mul_overflow(size, count, &total))) { 112 return fread(buf, size, count, stream); 115 return fread(buf, size, count, stream); 118 size_t __fwrite_chk(const void* __restrict buf, size_t size, size_t count, argument 121 if (__predict_false(__size_mul_overflow(size, count, &total))) { 123 return fwrite(buf, size, count, stream); 126 return fwrite(buf, size, count, stream); 209 ssize_t __readlinkat_chk(int dirfd, const char* path, char* buf, size_t size, size_ argument 215 __readlink_chk(const char* path, char* buf, size_t size, size_t buf_size) argument [all...] |
H A D | fsetxattr.cpp | 38 int fsetxattr(int fd, const char* name, const void* value, size_t size, int flags) { argument 40 int result = ___fsetxattr(fd, name, value, size, flags); 58 return setxattr(buf, name, value, size, flags);
|
H A D | getentropy_linux.c | 86 static int getentropy_phdr(struct dl_phdr_info *info, size_t size, void *data); 333 getentropy_phdr(struct dl_phdr_info *info, size_t size, void *data) argument
|
H A D | jemalloc_wrapper.cpp | 26 size_t size = BIONIC_ALIGN(bytes, pagesize); local 27 if (size < bytes) { 30 return je_memalign(pagesize, size); 40 void* je_memalign_round_up_boundary(size_t boundary, size_t size) { argument 48 return je_memalign(boundary, size);
|
H A D | libc_logging.cpp | 64 BufferOutputStream(char* buffer, size_t size) : total(0) { argument 66 end_ = buffer + size - 1; 160 // Writes number 'value' in base 'base' into buffer 'buf' of size 'buf_size' bytes.
|
H A D | malloc_common.cpp | 137 extern "C" int posix_memalign(void** memptr, size_t alignment, size_t size) { argument 140 return _posix_memalign(memptr, alignment, size); 142 return Malloc(posix_memalign)(memptr, alignment, size); 212 // "*overall_size" is set to the size of the "info" buffer 213 // "*info_size" is set to the size of a single entry 437 // [base, base+size). Must be called between malloc_disable and malloc_enable. 438 extern "C" int malloc_iterate(uintptr_t base, size_t size, argument 439 void (*callback)(uintptr_t base, size_t size, void* arg), void* arg) { 442 return _iterate(base, size, callback, arg); 444 return Malloc(iterate)(base, size, callbac [all...] |
H A D | mmap.cpp | 44 void* mmap64(void* addr, size_t size, int prot, int flags, int fd, off64_t offset) { argument 51 size_t rounded = BIONIC_ALIGN(size, PAGE_SIZE); 52 if (rounded < size || rounded > PTRDIFF_MAX) { 61 void* result = __mmap2(addr, size, prot, flags, fd, offset >> MMAP2_SHIFT); 66 int rc = madvise(result, size, MADV_MERGEABLE); 75 void* mmap(void* addr, size_t size, int prot, int flags, int fd, off_t offset) { argument 76 return mmap64(addr, size, prot, flags, fd, static_cast<off64_t>(offset));
|
H A D | ndk_cruft.cpp | 352 void* dlmalloc(size_t size) { argument 353 return malloc(size);
|
H A D | new.cpp | 26 void* operator new(std::size_t size) { argument 27 void* p = malloc(size); 29 __libc_fatal("new failed to allocate %zu bytes", size); 34 void* operator new[](std::size_t size) { argument 35 void* p = malloc(size); 37 __libc_fatal("new[] failed to allocate %zu bytes", size); 50 void* operator new(std::size_t size, const std::nothrow_t&) { argument 51 return malloc(size); 54 void* operator new[](std::size_t size, const std::nothrow_t&) { argument 55 return malloc(size); [all...] |
H A D | readlink.cpp | 36 ssize_t readlink(const char* path, char* buf, size_t size) { argument 37 return readlinkat(AT_FDCWD, path, buf, size);
|
H A D | scandir.cpp | 41 size_t size() { function in class:ScandirResult 87 size_t size = ((original->d_reclen + 3) & ~3); local 88 dirent* copy = reinterpret_cast<dirent*>(malloc(size)); 126 size_t size = names.size(); local 128 return size;
|
H A D | sys_shm.cpp | 68 int shmget(key_t key, size_t size, int flags) { argument 70 return syscall(SYS_shmget, key, size, flags); 72 return syscall(SYS_ipc, SHMGET, key, size, flags, 0, 0);
|
H A D | system_properties.cpp | 156 void* allocate_obj(const size_t size, uint_least32_t* const off); 306 void* prop_area::allocate_obj(const size_t size, uint_least32_t* const off) { argument 307 const size_t aligned = BIONIC_ALIGN(size, sizeof(uint_least32_t));
|
/bionic/libc/dns/net/ |
H A D | gethnamaddr.c | 431 debugprintf("size (%d) too big\n", res, n); 594 uint32_t size; local 602 fread(&size, 1, sizeof(size), proxy); 607 if (fread(&size, 1, sizeof(size), proxy) != sizeof(size)) return NULL; 608 size = ntohl(size); 614 if (ptr + size > hbuf_en 704 size_t size; local 867 socklen_t size; local [all...] |
/bionic/libc/dns/resolv/ |
H A D | res_cache.c | 405 * RDLENGTH: 16 : size of RDDATA in bytes 1164 int size; local 1166 size = sizeof(*e) + init->querylen + answerlen; 1167 e = calloc(size, 1); 1408 XLOG("cache size: %d", cache_size);
|
H A D | res_debug.c | 727 p_sockun(union res_sockaddr_union u, char *buf, size_t size) { argument 743 if (size > 0U) { 744 strncpy(buf, ret, size - 1); 745 buf[size - 1] = '0'; 759 /* takes an XeY precision/size value, returns a string representation. */ 776 /* converts ascii size/precision X * 10**Y(cm) to 0xXY. moves pointer. */ 1018 return (16); /* size of RR in octets */
|
H A D | res_init.c | 675 size_t size; local 687 size = sizeof(set->sin); 690 &set->sin, size); 691 if (size <= sizeof(statp->nsaddr_list[nserv])) 693 &set->sin, size); 701 size = sizeof(set->sin6); 704 &set->sin6, size); 705 if (size <= sizeof(statp->nsaddr_list[nserv])) 707 &set->sin6, size); 727 size_t size; local [all...] |
H A D | res_send.c | 782 socklen_t size = sizeof peer; local 786 (struct sockaddr *)(void *)&peer, &size) < 0 ||
|
/bionic/libc/include/ |
H A D | stdio.h | 100 #define BUFSIZ 1024 /* size of buffer used by setbuf */ 229 #define L_ctermid 1024 /* size for ctermid() */ 272 int vsnprintf(char *const __pass_object_size dest, size_t size, 274 return __builtin___vsnprintf_chk(dest, size, 0, __bos(dest), format, ap); 291 int snprintf(char *__restrict dest, size_t size, const char *__restrict format) 301 size_t size, const char *__restrict format, ...) __overloadable { 304 int result = __builtin___vsnprintf_chk(dest, size, 0, __bos(dest), format, va); 330 size_t fread(void *__restrict buf, size_t size, size_t count, 332 __enable_if(__unsafe_check_mul_overflow(size, count), "size * coun 424 snprintf(char *__restrict dest, size_t size, const char* _Nonnull format, ...) argument 439 fread(void *__restrict buf, size_t size, size_t count, FILE * __restrict stream) argument 463 fwrite(const void * __restrict buf, size_t size, size_t count, FILE * __restrict stream) argument 489 fgets(char* dest, int size, FILE* stream) argument [all...] |
H A D | string.h | 231 __error_if_overflows_dst(memcpy, dst, copy_amount, "size"); 235 __error_if_overflows_dst(memmove, dst, len, "size"); 239 __error_if_overflows_dst(memset, s, n, "size"); 283 /* Ignore dst size checks; they're handled in strncpy_chk */ 298 /* Ignore dst size checks; they're handled in strncpy_chk */ 310 const char *_Nonnull __restrict src, size_t size) __overloadable { 314 return __call_bypassing_fortify(strlcpy)(dst, src, size); 317 return __strlcpy_chk(dst, src, size, bos); 322 const char* _Nonnull __restrict src, size_t size) __overloadable { 326 return __call_bypassing_fortify(strlcat)(dst, src, size); 517 strlcpy(char* _Nonnull __restrict dst __pass_object_size, const char* _Nonnull __restrict src, size_t size) argument 536 strlcat(char* _Nonnull __restrict dst, const char* _Nonnull __restrict src, size_t size) argument [all...] |