Fixing #2 -> delete [] instead of delete.