Board index » cppbuilder » Stack Overflow in Visual C++

Stack Overflow in Visual C++


2007-10-27 12:58:09 AM
cppbuilder49
I created a C++ program and defined a huge struct. The struct size is
about 10000*100 bytes.
I compiled the program in Borland C++ Builder6 and everything is OK.
However, Visual C++.NET 2003 reported error as "Unhandled exception
at ... Stack overflow". Visual C++ will not report any problem if I
reduce the struct size to a much smaller one. Anybody know how to make
VC++ accept huge struct and not cause stack overflow?
Thank you in advance.
My Struct Sample:
typedef struct
{
double dVarXXX[10000];
}StructYYY;
typedef struct
{
StructYYY myStructYYY[100];
}StructZZZ;
 
 

Re:Stack Overflow in Visual C++

XXXX@XXXXX.COM schrieb:
Quote
I created a C++ program and defined a huge struct. The struct size is
about 10000*100 bytes.

I compiled the program in Borland C++ Builder6 and everything is OK.
However, Visual C++.NET 2003 reported error as "Unhandled exception
at ... Stack overflow". Visual C++ will not report any problem if I
reduce the struct size to a much smaller one. Anybody know how to make
VC++ accept huge struct and not cause stack overflow?
If you have a problem with your MS stuff and your Borland stuff works
fine, why are you asking in a Borland group? I would recommend to use
your Borland compiler.
Martin
--
Firma/Company: CRESD GmbH
WWW: www.cresd.de
PGP-Key: www.cresd.de/edv/pgpkey.txt
Open BC (Einladung) www.openbc.com/go/invita/4561755