[ODE] Stack overflow

Marco Grubert mgrubert at conitec.net
Thu Jan 30 21:01:18 2003


I am still looking for some "best practice" tutorial, but so far I have
found three solutions:

a) use Win32 exception handling (__try/__except) to catch the stack overflow
b) set linker to reserve large amount of memory (max. 1GB I believe) and
hope that we don't go beyond this amount (apparently stack is allocated as
needed so the value can be large)
c) replace alloca() calls with mallocs and/or use custom memory handler

Regards,
  Marco Grubert