At 02:20 PM 1/24/00 +0100, you wrote: >Hiya all.. > >I'm currently fighting a very weird random hitting bug. The problem arises >when someone tries to Redit a room, and *boom* the mud crashes with >coredump and everything. Since your backtrace has nothing whatsoever relating to room editing in it... are you certain that redit wasn't just a coincidence? Read on for more info... >Apparently it comes from DG_Scripts.c (Yes, I run with DG_Scripts :) > >GDB tells me the following: >a Backtrack shows: > >#0 0x80c306b in script_driver (go=0x4013bed8, trig=0x8241220, type=2, >mode=1) > at dg/dg_scripts.c:2862 >#1 0x80bd9c8 in trig_wait_event (info=0x8554ad0) at dg/dg_scripts.c:483 >#2 0x80b9752 in process_events () at dg/dg_event.c:81 This indicates that the crash happened when trying to continue a script that paused itself (via the "wait" command). I expect the problem is the owner of the script (mob/object) no longer exists; either it was purged, killed, junked, eaten, etc. There is a bug in the event system that DG Scripts uses by default that will cause this. I haven't put a fix into what will probably be called pl8 yet. However, in my own mud, in dg_scripts.c, I've made the following changes: * all of this is MailerCode(tm) 1) in the struct wait_event_data definition, I've added a member "id" of type long. 2) in process_wait(): after the three existing wait_event_obj->MEMBER assignments, I have the following: if (type == MOB_TRIGGER) wait_event_obj->id = GET_ID((struct char_data *)go); else if (type == OBJ_TRIGGER) wait_event_obj->id = GET_ID((struct obj_data *)go); else wait_event_obj->id = 0; 3) in the trig_wait_event function [ EVENT(trig_wait_event) ], add: long id = wait_event_obj->id; free(wait_event_obj); /* should already exist */ /* if the char/obj no longer exists, abort */ if (id && (((type == MOB_TRIGGER) && (find_char(id)==NULL)) || ((type == OBJ_TRIGGER) && (find_obj(id)==NULL)))) return; +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 04/10/01 PDT