问题
Is there a way to grow an array in C, but only if the memory can be grown in place (That is, fail to grow if the pointer needs to be changed)?
回答1:
In standard C there is no function capable of doing that.
来源:https://stackoverflow.com/questions/21630787/c-realloc-that-fails-if-the-allocation-cannot-grow-in-place