void ctl_net_mem_trim(void *p,
                      size_t byteSize);

ctl_net_mem_trim is a wrapper around the trim member of the of the network memory manager (see CTL_NET_MEM_DRIVER_t and ctl_net_mem_alloc_fn_t).

This is a request to reduce the memory allocated and pointed to by p to byteSize bytes. It is guaranteed that byteSize is less than the currently allocated size for p. The network memory allocator is not required to trim its memory allocation, this call is an indication to the memory allocator that the extra memory will not be used by the network library and the allocator can recover it. It is acceptable for the implementation of the underlying trim function to do nothing.