[DGD] Fwd: Unusual Driver Crash - what do I do next?

Felix A. Croes felix at dworkin.nl
Mon Dec 4 14:39:04 CET 2006


Neil McBride <sarak at castinian.org> wrote:

>[...]
> So, I hunted through the kernel lib and started dropping small
> debugging messages here and there hoping to find a starting point to
> look at in my own code.  Eventually, I modified the receive_message
> function in /kernel/obj/telnet.c to send a message to the player (was
> "aaa\n") before it does it's normal thing.  This meant I was getting
> the extra line of aaa output after I pressed enter and before the
> normal responses.  I was expecting to get this after the final 'enter'
> before the crash, but it doesn't happen this way.  It just crashes.
>
> I followed an email from Dworkin last year about tracing the stack but
> I don't really know what it means - I think it's saying it tries to
> call receive_message in something but I'm not sure what.  The last 20
> lines or so are at the bottom if that helps anyone.

The reason you don't see that "aaa" is that this is only sent after
the execution round finishes, which it never does.

This is indeed a case of infinite recursion, as I can tell from the
stack depth (~58000 calls) of the backtrace.  What you should do
is use call_limited() to make sure that a proper stack limit is
imposed on the code you run.  You'll still get an error after that,
but it will be an LPC error with an LPC error message that will allow
you to properly track down what is going wrong.

Regards,
Dworkin



More information about the DGD mailing list