VS2005 stack overflow的问题

    Visual Studio 2005中,关于堆溢出(Stack overflow)问题的解决

      程序build没问题,运行时直接跳到intel的chkstk.asm文件中去了,说明你的程序中某个数组太大了,超过了
默认stack的size.解决方法有两个:


1)project property->Configuration Properties->Linker->System->Stack Reserve Size
改成10000000,就可以了,注意是7个0哦


2)将数组改成指针,然后用new或malloc在heap中动态分配。

 

To set this linker option in the Visual Studio development environment

  1. Open the project's Property Pages dialog box. For details, see Setting Visual C++ Project Properties.

  2. Click the Linker folder.

  3. Click the System property page.

  4. Modify one of the following properties:

    • Stack Commit Size

    • Stack Reserve Size

你可能感兴趣的:(c,properties,System,Build,dialog,linker)