Files
C/data_structures/dynamic_array/dynamic_array.c
Enzo Veroneze 1b3a1ca91e fix: remove double/unintended free (#1143)
The call to realloc() already frees the previously allocated memory if necessary.
By the man page of realloc(): "f the area pointed to was moved, a free(ptr) is done.",
and free(): "If free(ptr) has already been called before, undefined behavior occurs.".
2022-11-09 23:19:01 -06:00

1.7 KiB