// Created by Dmitry Vostokov on 22/05/2013. // Copyright (c) 2013 Software Diagnostics Institute. All rights reserved. #include "stdafx.h" #include #include #define SIZE 100 int _tmain(int argc, _TCHAR* argv[]) { char *parr[SIZE]; for (int i = 0; i < SIZE; ++i) { parr[i] = (char *)malloc(SIZE); strcpy(parr[i], "Hello Crash!"); if (i == SIZE/2) { strcpy(parr[i]-SIZE/10, "Hello Crash!"); } } for (int i = 0; i < SIZE; ++i) { free(parr[i]); } return 0; }