Re: [crash bug] dg scripts

From: Andrey Fidrya (andrey@ALEX-UA.COM)
Date: 02/28/98


> So far they seem to work fine, unless I try to use wait in any of its 3
> formats:
> wait 1 s
[...]
> this is a greet program, and goes off when a player enters the room with
> the mob its attached to. if its only say hello, it works fine. with the
> wait added, 2-3 seconds after you enter the mud crahes.

There is a bug in dg_event.c... I think it will be fixed in next release...
Function frees the memory then tries to work with it and this causes crashes
under WIN95.

In dg_events.c replace process_events function with this one:

void process_events(void)
{
  struct event_info *e = event_list;
  struct event_info *del;

  while (e) {
    if (--(e->time_remaining) == 0) {
      e->func(e->info);
      del = e;
      e = e->next;
      remove_event(del);
    } else
      e = e->next;
  }
}

Should work fine now.

  Andrey (andrey@alex-ua.com)
    aka Zmey//RMUD


     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/15/00 PST