Invalid write of size 1 ... Address 0x........ is 1 bytes inside a block of size 10 free'd ... Block was alloc'd at at 0x........: malloc (vg_replace_malloc.c:...) ... Invalid write of size 1 ... Address 0x........ is 1 bytes before a block of size 10 alloc'd at 0x........: malloc (vg_replace_malloc.c:...) ...