Lines Matching defs:allocated
40 void* greedy_realloc(void **p, size_t *allocated, size_t need, size_t size) {
45 assert(allocated);
47 if (*allocated >= need)
62 *allocated = newalloc;
66 void* greedy_realloc0(void **p, size_t *allocated, size_t need, size_t size) {
71 assert(allocated);
73 prev = *allocated;
75 q = greedy_realloc(p, allocated, need, size);
79 if (*allocated > prev)
80 memzero(q + prev * size, (*allocated - prev) * size);