c_koans
c_koans copied to clipboard
No actual reallocation and UB in about_arrays.c
In the file about_arrays.c on line 81 the array int is allocated with 5 elements (defined on line 80), then in line 96 this array is reallocated again with 5 elements (with the same size variable), and then access to the 6th (on index 5) element of the array (of 5 elements) is undefined behavior