Home
last modified time | relevance | path

Searched refs:element_size (Results 1 – 2 of 2) sorted by relevance

/system/bt/osi/src/
Darray.c31 size_t element_size; member
42 array_t *array_new(size_t element_size) { in array_new() argument
43 assert(element_size > 0); in array_new()
45 array_t *array = osi_calloc(sizeof(array_t) + element_size * INTERNAL_ELEMENTS); in array_new()
47 array->element_size = element_size; in array_new()
70 return array->data + (index * array->element_size); in array_at()
87 …st current capacity of %zu elements of size %zu.", __func__, array->capacity, array->element_size); in array_append_ptr()
92 memcpy(array_at(array, array->length - 1), data, array->element_size); in array_append_ptr()
100 void *new_data = realloc(is_moving ? NULL : array->data, new_capacity * array->element_size); in grow()
105 memcpy(new_data, array->internal_storage, array->length * array->element_size); in grow()
/system/bt/osi/include/
Darray.h30 array_t *array_new(size_t element_size);