Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Bug Reports

Development::Bug Reports Post detailed bug reports and what you would like to see next in the emu here.

Reply
 
Thread Tools Display Modes
  #1  
Old 04-24-2009, 10:29 PM
Secrets's Avatar
Secrets
Demi-God
 
Join Date: May 2007
Location: b
Posts: 1,450
Default Crash on EntityList::AIYellForHelp?

I'm seeing a lot of this in core dumps. Whenever this function is called, it occasionally puts this out with this:

Code:
0x081d080a in EntityList::AIYellForHelp (this=0x8373ec0, sender=0x8bf3738, attacker=0x8c265b0) at aggro.cpp:437
And when I go to line 437, it's a bunch of conditionals:

Code:
if (
			mob != sender
			&& mob != attacker
//			&& !mob->IsCorpse()
//			&& mob->IsAIControlled()
			&& mob->GetPrimaryFaction() != 0
			&& mob->DistNoRoot(*sender) <= r
			&& !mob->IsEngaged()
			)
which I assume is being met, due to this being filled in as well as attacker & sender, but since it is generating a core dump I can only assume not.

Anyone have an idea on how to fix this?
Reply With Quote
  #2  
Old 04-25-2009, 03:59 AM
Derision
Developer
 
Join Date: Feb 2004
Location: UK
Posts: 1,540
Default

Is this crash occurrng with the current stock source ?

It would appear that none of the pointers can be NULL at that point, so the only reason for a crash would be a pointer to a mob instance that has been destroyed and not been removed from the entity list.

I made some fixes a while ago, so that shouldn't be able to happen. Without knowing how to reproduce it, it will difficult to track down.
Reply With Quote
  #3  
Old 04-25-2009, 04:56 AM
Secrets's Avatar
Secrets
Demi-God
 
Join Date: May 2007
Location: b
Posts: 1,450
Default

Quote:
Originally Posted by Derision View Post
Is this crash occurrng with the current stock source ?

It would appear that none of the pointers can be NULL at that point, so the only reason for a crash would be a pointer to a mob instance that has been destroyed and not been removed from the entity list.

I made some fixes a while ago, so that shouldn't be able to happen. Without knowing how to reproduce it, it will difficult to track down.
Yes, this is in current stock source, with minor edits, to none of which were aggro.cpp.. Unfortunately, i've never witnessed it go down, i've just seen core dumps of it. :/

I'll look into the entity list and see if anything is screwed up there. I might have missed something when I merged in SVN, but I doubt it.
Reply With Quote
  #4  
Old 04-25-2009, 05:02 AM
Secrets's Avatar
Secrets
Demi-God
 
Join Date: May 2007
Location: b
Posts: 1,450
Default

Ok, looked in source, didn't see any of the changes related to the entity list that I made nor aggro.cpp or hate_list.cpp. Kind of lost still. :/
Reply With Quote
  #5  
Old 04-25-2009, 05:47 AM
Derision
Developer
 
Join Date: Feb 2004
Location: UK
Posts: 1,540
Default

The fixes I made that were meant to stop that where in the mob destructor:

mob.cpp
Code:
Mob::~Mob()
{
        // Our Entity ID is set to 0 in NPC::Death. This leads to mobs hanging around for a while in
        // the entity list, even after they have been destroyed. Use our memory pointer to remove the mob
        // if our EntityID is 0.
        //

        if(GetID() > 0)
                entity_list.RemoveMob(GetID());
        else
                entity_list.RemoveMob(this);
and the end of the client destructor:

client.cpp
Code:
Client::~Client() {
<snip>
        entity_list.RemoveClient(this);
}

void Client::SendLogoutPackets() {
If you have the code in green, I am not sure what could be causing the problem.
Reply With Quote
  #6  
Old 04-25-2009, 02:12 PM
Secrets's Avatar
Secrets
Demi-God
 
Join Date: May 2007
Location: b
Posts: 1,450
Default

I have both of the code in green. I'm not sure what could be causing it, still. Is there any way to use gdb to figure out the issue otherwise?
Reply With Quote
  #7  
Old 04-25-2009, 02:34 PM
KLS
Administrator
 
Join Date: Sep 2006
Posts: 1,348
Default

I've seen a few core dumps from PEQ in the past that have this. The stack trace was really odd too, I couldn't figure out where it was crashing at all.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 08:24 PM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3