Obj->next Check Fix for EmberMUD
                         Fix Sheet by Rindar (Ron Cole)
                         Fixes by Raven (Laurie Zenner)


The Bug: Do you constantly get a strange BUG message in your log 
file when-ever you start your MUD?  If so, you may have a very
harmless but annoying bug in your boot.c file.

The Check:  Look in your log file to see if you get this message 
when you boot up: [*****] BUG: Obj->next == object_list  If you do,
you probably have this bug (or another bug that is even worse).


The Bugfix:  Open DB.C and go to the end of function create_object().  
Just before the return statement, you should find a paragraph 
that looks like:
   if (obj->next != object_list)
      obj->next = object_list
   else
      bug( "Obj->next == object_list!", 0);
   object_list = obj;
   pObjIndex->count++;

object_list points to the last object loaded.  On the first time 
around, object_list will be NULL, as will obj->next.  This is as 
it should be, but the code doesn't check for this.  So, I put a fix 
in that looks like:

   if (obj->next != object_list)
      obj->next = object_list
   else if ( object_list != NULL ) <===== just put in this small if statement
      bug( "Obj->next == object_list!", 0);
   object_list = obj;
   pObjIndex->count++;

You shouldn't see that error message again.  If you do, then you really do 
have a problem somewhere.


-- Raven 




 =============================================================================
/   ______ _______ ____   _____   ___ __    _ ______    ____  ____   _____   /
\  |  ____|__   __|  _ \ / ____\ / _ \| \  / |  ____|  / __ \|  _ \ / ____\  \
/  | |__     | |  | |_| | |     | |_| | |\/| | |___   | |  | | |_| | |       /
/  | ___|    | |  | ___/| |   __|  _  | |  | | ____|  | |  | |  __/| |   ___ \
\  | |       | |  | |   | |___| | | | | |  | | |____  | |__| | |\ \| |___| | /
/  |_|       |_|  |_|  o \_____/|_| |_|_|  |_|______|o \____/|_| \_|\_____/  \
\                                                                            /
 ============================================================================

------------------------------------------------------------------------------
ftp://ftp.game.org/pub/mud      FTP.GAME.ORG      http://www.game.org/ftpsite/
------------------------------------------------------------------------------

 This file came from FTP.GAME.ORG, the ultimate source for MUD resources.

------------------------------------------------------------------------------