At 11:11 AM 11/30/2004 -0200, Paulo de Oliveira Eneas writeth:
>Dear list members,
>
>I working in a project that uses a very big struct whose size is approx 4.0
>MB.

You should be using dynamically allocated memory using new/delete and I
can't imagine why you need such a big structure - either you have lots of
large arrays in there (bad idea) or a bazillion variables, neither of which
I could imagine being acceptable.  By making it global, you are potentially
making your program size 4MB (depends on the compiler).  Under Windows and
most other OSes, you only get a 1MB stack, so the program naturally will
crash when you try to put 4MB on the stack.


Thomas J. Hruska
[EMAIL PROTECTED]

Shining Light Productions
Home of the Nuclear Vision scripting language and ProtoNova web server.
http://www.slproweb.com/



To unsubscribe, send a blank message to <mailto:[EMAIL PROTECTED]>.


Yahoo! Groups Sponsor
ADVERTISEMENT
click here
Web Bug from http://us.adserver.yahoo.com/l?M=298184.5639630.6699735.3001176/D=groups/S=:HM/A=2434971/rand=493300111


Yahoo! Groups Links

Reply via email to