The allocator that comes with free rtos (I assume he&#x27;s using it as he mentions pvPortMalloc) can be extended to support realloc efficiently without too much trouble so that it will resize if possible. For example <a href="https:&#x2F;&#x2F;github.com&#x2F;hello&#x2F;heap_6" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;hello&#x2F;heap_6</a>