[comp.lang.c] Adjusting the stack length in TC 2.0

rlscon@unix.cis.pitt.edu (Robert Sillett) (10/20/90)

I've run into the wonderful "Stack overflow!" error while using Turbo
C 2.0.  However, I can't seem to increase the stack length.  All I've
found in the manuals are references to two global variables _heaplen
and _stklen.  This puzzles me since MSC 5.1 lets me set the stack with
a linker option.  Can I set the stack with TLINK or must I do it in
code?

Thanks in advance.

Robert Sillett


-- 
===============================================================================
Robert L. Sillett                          sillett%edc3@unix.cis.pitt.edu
Epidemiology Data Center                   sillett%edc3@vms.cis.pitt.edu
Univ. of Pittsburgh

gordon@osiris.cso.uiuc.edu (John Gordon) (10/21/90)

	You are on the right track with _stklen.  Globally, set it equal to
the desired stack size (in bytes).

	example:
			unsigned _stklen = 64000U;  /* for 64K stack */