[DGD] segmentation fault

Shentino shentino at gmail.com
Tue Feb 12 20:52:43 CET 2008


Par's most likely right on it being a stack problem.

If it were an infinite loop, DGD would hang instead of crash.

If you're enclosing it in an rlimits and it's still segfaulting, then
either you've got one humungo stack limit (unlikely), or the segfault
is not due to a stack overflow.

Try running DGD under a debugger and when it crashes, look at the
stack trace.  If it's anything other than a bunch of i_interpret's,
then you're not having a stack overflow.

On 2/12/08, Par Winzell <zell at skotos.net> wrote:
> Nobody is suggesting you use rlimits as a hack to ignore the real
> problem. It's a lot easier to find your bug if DGD has a chance to print
> a stack trace rather than crashing. Only extremely well tested code
> should ever run without a stack limit.
>
> On 2/12/08 12:10 PM, chris . wrote:
> > I almost tried rlimits, but thought wouldn't rlimits simply be fixing a bug i created?  in other words
> > if theres a bad loop somewhere shouldnt i try and resolve that?
> > rlimits needs to be associated with a catch() right?  Ive never played with them, but i have a good
> > realization of what they do.  I looked into them as a solution but opted to solve the 'real' problem.
> > But maybe i misunderstand some aspect of dgd and rlimits.
> > off the top of my head than, i would do something like
> > catch() {rlimits(ST_SYSTEM_TICKS-1, ST_SYSTEM_MEMORY-1) { -subject code- } }
> >
> > Is my bug because im not using rlimits where i should or because i have bad code?
> > Well thanks:-)
> > chris
> >
> > _________________________________________________________________
> > Connect and share in new ways with Windows Live.
> > http://www.windowslive.com/share.html?ocid=TXT_TAGHM_Wave2_sharelife_012008___________________________________________
> > https://mail.dworkin.nl/mailman/listinfo/dgd
>
> ___________________________________________
> https://mail.dworkin.nl/mailman/listinfo/dgd
>



More information about the DGD mailing list