#include #include "../include/memory.h" void *reallocate(void *pointer, size_t oldCap, size_t newCap){ if(newCap == 0){ free(pointer); return NULL; } (void)oldCap; void *result = realloc(pointer,newCap); return result; }