[plug] Assistance requested for killed program

Peter F Bradshaw pfb at exadios.com
Thu Nov 24 19:04:00 WST 2005


Hi James;

On Thu, 24 Nov 2005, James Leven wrote:

> G'day all;
>
> I have written a C++ program with a recursive method for one of the
> classes.

Not an infinitely recursive method I hope.

>
> If I run this program with test parameters, it works well; but for a
> serious application, I eventually get the message "killed".   My guess
> is that I have run out of stack, but is there any way to monitor this,
> or to extend the stack?

If bash is your shell then there is a builtin command called ulimit.

ulimit -a

will show your current limits. The libc routines getrlimit(2) and
setrlimit(2) are avaliable.

>
> Any suggestions that I could implement in the program to reduce the
> problem would be gratefully received.
>
> Regards
> Jim Leven
> jleven at geoseis.com.au

Cheers

-- 
Peter F Bradshaw, http://www.exadios.com, ICQ 75431157 (exadios).
Public key at www.exadios.com/pfb.pgp.key and www.exadios.com/pfb.gpg.key
"I love truth, and the way the government still uses it occasionally to
 keep us guessing." - Sam Kekovich.



More information about the plug mailing list