Closed apo126 closed 8 years ago
00448430 00000000 WorldObject::IsInMap+10 004CF303 00000000 WorldObject::IsWithinLOSInMap+13 006EF581 00000000 CreatureAI::CanCastSpell+A1 006EF711 00000000 CreatureAI::DoCastSpellIfCan+A1
These are probably the most important lines in telling what produced the error;
As we see, it crashed when executing the function IsInMap , called by IsWithinLOSInMap, called by CanCastSpell. My guess is that the error is to be found within one of these three functions, as I doubt DoCastSpellIfCan is the sinner - it could be, though.
You say you can provide more info. Can you provide info about at what line IsInMap crashed the server?
"Can you provide info about at what line IsInMap crashed the server?"
To Phatcat, could you please tell me how to get the info about what line IsInMap.
if you want to quote someone you can simply add a > before the message. It looks a bit nicer =)
And if you want to message someone specifically add a @ before the name, like @apo126 - that way you're sure the message reaches them.
Back to the point: I'm guessing you have that info from the crash file. Could you try rebuilding the server in debug mode, then recreate the issue. At least on windows we get told what line is the trouble-maker, ie: (incoming random example from one of my own crash files)
0076F33E 00000000 Map::Remove
+1CE c:\mangos\mangos-classic\src\game\map.cpp line 655
As you can see, my crash file includes in the call stack the source file and at which line in the source file, right next to the function call.
By the way, if the issue is not within one of those 4 functions on the top of the call stack, then it is in the script for the boss:
0859A3AB 00000000 boss_kiggler_the_crazedAI::UpdateAI+AB
Revision: * * *
Date 30:5:2016. Time 14:44
//=====================================================
*** Hardware ***
Processor: Intel(R) Core(TM) i5-3210M CPU @ 2.50GHz
Number Of Processors: 4
Physical Memory: 4194303 KB (Available: 4194303 KB)
Commit Charge Limit: 4194303 KB
*** Operation System ***
Windows 7 Service Pack 1 (Version 6.1, Build 7601)
//=====================================================
Exception code: C0000005 ACCESS_VIOLATION
Fault address: 004C6C3F 01:000C5C3F D:\Games\Mangos\mangosd.exe
Registers:
EAX:0000002F
EBX:0033A990
ECX:00000000
EDX:0000008D
ESI:00018BBE
EDI:0992F9DC
CS:EIP:0023:004C6C3F
SS:ESP:002B:0992F998 EBP:0992F9A4
DS:002B ES:002B FS:0053 GS:002B
Flags:00010202
Call stack:
Address Frame Function SourceFile
004C6C3F 00000000 WorldObject::IsInMap+2F d:\mangos-wotlk-master\src\game\object.h line 541
005FCC57 00000000 WorldObject::IsWithinLOSInMap+27 d:\mangos-wotlk-master\src\game\object.cpp line 1167
00A6893A 00000000 CreatureAI::CanCastSpell+FA d:\mangos-wotlk-master\src\game\creatureai.cpp line 58
00A68B64 00000000 CreatureAI::DoCastSpellIfCan+C4 d:\mangos-wotlk-master\src\game\creatureai.cpp line 106
095796BC 00000000 boss_kiggler_the_crazedAI::UpdateAI+EC d:\mangos-wotlk-master\src\scriptdev2\scripts\outland\gruuls_lair\boss_high_king_maulgar.cpp line 349
006B027F 00000000 Creature::Update+45F d:\mangos-wotlk-master\src\game\creature.cpp line 600
004CC417 00000000 WorldObject::UpdateHelper::Update+37 d:\mangos-wotlk-master\src\game\object.h line 439
006DD434 00000000 MaNGOS::ObjectUpdater::Visit+A4 d:\mangos-wotlk-master\src\game\gridnotifiersimpl.h line 46
006C4C1F 00000000 VisitorHelper<MaNGOS::ObjectUpdater,Creature>+F d:\mangos-wotlk-master\src\framework\gamesystem\typecontainervisitor.h line 51
006C4C70 00000000 VisitorHelper<MaNGOS::ObjectUpdater,Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > >+10 d:\mangos-wotlk-master\src\framework\gamesystem\typecontainervisitor.h line 57
006C4D23 00000000 VisitorHelper<MaNGOS::ObjectUpdater,GameObject,TypeList<Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > > >+23 d:\mangos-wotlk-master\src\framework\gamesystem\typecontainervisitor.h line 58
006C4AF5 00000000 VisitorHelper<MaNGOS::ObjectUpdater,TypeList<GameObject,TypeList<Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > > > >+15 d:\mangos-wotlk-master\src\framework\gamesystem\typecontainervisitor.h line 65
006DD2DD 00000000 TypeContainerVisitor<MaNGOS::ObjectUpdater,TypeMapContainer<TypeList<GameObject,TypeList<Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > > > > >::Visit+1D d:\mangos-wotlk-master\src\framework\gamesystem\typecontainervisitor.h line 80
006C2C6A 00000000 Grid<Player,TypeList<Player,TypeList<Creature,TypeList<Corpse,TypeList<Camera,TypeNull> > > >,TypeList<GameObject,TypeList<Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > > > >::Visit<MaNGOS::ObjectUpdater>+1A d:\mangos-wotlk-master\src\framework\gamesystem\grid.h line 81
006C2CD9 00000000 NGrid<8,Player,TypeList<Player,TypeList<Creature,TypeList<Corpse,TypeList<Camera,TypeNull> > > >,TypeList<GameObject,TypeList<Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > > > >::Visit<MaNGOS::ObjectUpdater,TypeList<GameObject,TypeList<Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > > > >+29 d:\mangos-wotlk-master\src\framework\gamesystem\ngrid.h line 157
006C2DD5 00000000 Map::Visit<MaNGOS::ObjectUpdater,TypeMapContainer<TypeList<GameObject,TypeList<Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > > > > >+A5 d:\mangos-wotlk-master\src\game\map.h line 476
006DCBC2 00000000 Map::Update+352 d:\mangos-wotlk-master\src\game\map.cpp line 510
006DC85A 00000000 DungeonMap::Update+1A d:\mangos-wotlk-master\src\game\map.cpp line 1428
0099A7FD 00000000 MapManager::Update+10D d:\mangos-wotlk-master\src\game\mapmanager.cpp line 175
005C0DBF 00000000 World::Update+28F d:\mangos-wotlk-master\src\game\world.cpp line 1522
0054CED9 00000000 WorldRunnable::run+89 d:\mangos-wotlk-master\src\mangosd\worldrunnable.cpp line 59
0058FC41 00000000 MaNGOS::Thread::ThreadTask+21 d:\mangos-wotlk-master\src\shared\threading.cpp line 84
0058F7F2 00000000 std::_Bind<1,void,void (__cdecl*const)(void *),void *>::_Do_call<,0>+42 c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional line 1149
0058F75A 00000000 std::_Bind<1,void,void (__cdecl*const)(void *),void *>::operator()<>+3A c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional line 1138
0058FD2A 00000000 std::_LaunchPad<std::_Bind<1,void,void (__cdecl*const)(void *),void *> >::_Run+4A c:\program files (x86)\microsoft visual studio 12.0\vc\include\thr\xthread line 196
0058FCC7 00000000 std::_LaunchPad<std::_Bind<1,void,void (__cdecl*const)(void *),void *> >::_Go+17 c:\program files (x86)\microsoft visual studio 12.0\vc\include\thr\xthread line 187
5C9C2FA6 00000000 ?_Release@_Pad@std@@QAEXXZ+D6
5C813651 00000000 _beginthreadex+1A1
5C813861 00000000 _endthreadex+181
760A338A 00000000 BaseThreadInitThunk+12
77639902 00000000 RtlInitializeExceptionChain+63
776398D5 00000000 RtlInitializeExceptionChain+36
========================
Local Variables And Parameters
Call stack:
Address Frame Function SourceFile
004C6C3F 00000000 WorldObject::IsInMap+2F d:\mangos-wotlk-master\src\game\object.h line 541
punting on symbol this
punting on symbol obj
005FCC57 00000000 WorldObject::IsWithinLOSInMap+27 d:\mangos-wotlk-master\src\game\object.cpp line 1167
punting on symbol this
punting on symbol obj
punting on symbol oz
punting on symbol oy
punting on symbol ox
00A6893A 00000000 CreatureAI::CanCastSpell+FA d:\mangos-wotlk-master\src\game\creatureai.cpp line 58
punting on symbol this
punting on symbol pTarget
punting on symbol pSpell
punting on symbol isTriggered
00A68B64 00000000 CreatureAI::DoCastSpellIfCan+C4 d:\mangos-wotlk-master\src\game\creatureai.cpp line 106
punting on symbol castResult
punting on symbol pSpell
punting on symbol this
punting on symbol pTarget
punting on symbol uiSpell
punting on symbol uiCastFlags
punting on symbol uiOriginalCasterGUID
punting on symbol pCaster
095796BC 00000000 boss_kiggler_the_crazedAI::UpdateAI+EC d:\mangos-wotlk-master\src\scriptdev2\scripts\outland\gruuls_lair\boss_high_king_maulgar.cpp line 349
punting on symbol this
punting on symbol uiDiff
006B027F 00000000 Creature::Update+45F d:\mangos-wotlk-master\src\game\creature.cpp line 600
punting on symbol this
punting on symbol update_diff
punting on symbol diff
004CC417 00000000 WorldObject::UpdateHelper::Update+37 d:\mangos-wotlk-master\src\game\object.h line 439
punting on symbol this
punting on symbol time_diff
006DD434 00000000 MaNGOS::ObjectUpdater::Visit+A4 d:\mangos-wotlk-master\src\game\gridnotifiersimpl.h line 46
punting on symbol helper
punting on symbol iter
punting on symbol this
punting on symbol m
006C4C1F 00000000 VisitorHelper<MaNGOS::ObjectUpdater,Creature>+F d:\mangos-wotlk-master\src\framework\gamesystem\typecontainervisitor.h line 51
punting on symbol v
punting on symbol c
006C4C70 00000000 VisitorHelper<MaNGOS::ObjectUpdater,Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > >+10 d:\mangos-wotlk-master\src\framework\gamesystem\typecontainervisitor.h line 57
punting on symbol v
punting on symbol c
006C4D23 00000000 VisitorHelper<MaNGOS::ObjectUpdater,GameObject,TypeList<Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > > >+23 d:\mangos-wotlk-master\src\framework\gamesystem\typecontainervisitor.h line 58
punting on symbol v
punting on symbol c
006C4AF5 00000000 VisitorHelper<MaNGOS::ObjectUpdater,TypeList<GameObject,TypeList<Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > > > >+15 d:\mangos-wotlk-master\src\framework\gamesystem\typecontainervisitor.h line 65
punting on symbol v
punting on symbol c
006DD2DD 00000000 TypeContainerVisitor<MaNGOS::ObjectUpdater,TypeMapContainer<TypeList<GameObject,TypeList<Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > > > > >::Visit+1D d:\mangos-wotlk-master\src\framework\gamesystem\typecontainervisitor.h line 80
punting on symbol this
punting on symbol c
006C2C6A 00000000 Grid<Player,TypeList<Player,TypeList<Creature,TypeList<Corpse,TypeList<Camera,TypeNull> > > >,TypeList<GameObject,TypeList<Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > > > >::Visit<MaNGOS::ObjectUpdater>+1A d:\mangos-wotlk-master\src\framework\gamesystem\grid.h line 81
punting on symbol this
punting on symbol visitor
006C2CD9 00000000 NGrid<8,Player,TypeList<Player,TypeList<Creature,TypeList<Corpse,TypeList<Camera,TypeNull> > > >,TypeList<GameObject,TypeList<Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > > > >::Visit<MaNGOS::ObjectUpdater,TypeList<GameObject,TypeList<Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > > > >+29 d:\mangos-wotlk-master\src\framework\gamesystem\ngrid.h line 157
punting on symbol this
punting on symbol x
punting on symbol y
punting on symbol visitor
006C2DD5 00000000 Map::Visit<MaNGOS::ObjectUpdater,TypeMapContainer<TypeList<GameObject,TypeList<Creature,TypeList<DynamicObject,TypeList<Corpse,TypeNull> > > > > >+A5 d:\mangos-wotlk-master\src\game\map.h line 476
punting on symbol this
punting on symbol cell
punting on symbol visitor
punting on symbol cell_y
punting on symbol x
punting on symbol y
punting on symbol cell_x
006DCBC2 00000000 Map::Update+352 d:\mangos-wotlk-master\src\game\map.cpp line 510
punting on symbol cell
punting on symbol pair
punting on symbol cell_id
punting on symbol y
punting on symbol x
punting on symbol plr
punting on symbol area
punting on symbol this
punting on symbol t_diff
punting on symbol updater
punting on symbol world_object_update
punting on symbol grid_object_update
006DC85A 00000000 DungeonMap::Update+1A d:\mangos-wotlk-master\src\game\map.cpp line 1428
punting on symbol this
punting on symbol t_diff
0099A7FD 00000000 MapManager::Update+10D d:\mangos-wotlk-master\src\game\mapmanager.cpp line 175
punting on symbol iter
punting on symbol this
punting on symbol diff
punting on symbol iter
005C0DBF 00000000 World::Update+28F d:\mangos-wotlk-master\src\game\world.cpp line 1522
punting on symbol i
punting on symbol this
punting on symbol diff
0054CED9 00000000 WorldRunnable::run+89 d:\mangos-wotlk-master\src\mangosd\worldrunnable.cpp line 59
punting on symbol diff
punting on symbol this
punting on symbol realCurrTime
punting on symbol realPrevTime
punting on symbol prevSleepTime
0058FC41 00000000 MaNGOS::Thread::ThreadTask+21 d:\mangos-wotlk-master\src\shared\threading.cpp line 84
punting on symbol param
punting on symbol _task
0058F7F2 00000000 std::_Bind<1,void,void (__cdecl*const)(void *),void *>::_Do_call<,0>+42 c:\program files (x86)\microsoft visual studio 12.0\vc\include\functional line 1149
punting on symbol this
Yeeeaaaaah, feel free to tell me whats causing it because I have encountered this crash on multiple occasions. There seems to be an issue in a particular moment when you try to call "GetMap" and the target is in some weird state with the pointer being messed up. I need to know how to reproduce it sadly.
Please, try this https://github.com/cmangos/mangos-wotlk/commit/7d0a5dcba4be042c21918b7d946eb003ccac5448 to see if this fix the issue.
@killerwife Actually, you may just have been given a mothod of reproduction right here, as it seems @apo126 is able to reproduce this somewhat easily using Gruul's Lair.
Unless you're talking about a way to reproduce a messed up pointer... Then we're out of my league.
Well then describe it here?
@apo126
I tried three times in Gruul's Lair, every time it crashed. If you need other info, please ask me.
Killerwife is asking for some of that 'other' info, like method you use to keep being able to reproduce this.
But going by my guess, it would seem like it happens somewhere during the fight against a scripted guy, clearly indicated by this;
095796BC 00000000 boss_kiggler_the_crazedAI::UpdateAI+EC d:\mangos-wotlk-master\src\scriptdev2\scripts\outland\gruuls_lair\boss_high_king_maulgar.cpp line 349
@cala mangos-wotlk with Latest commit 4414e48 also crashed in 30 seconds after fighting against High King Maulgar began. And the last message on mangosd is "creature 81643 stopped attacking creature 1".
@apo126 Could you test if you are still able to reproduce this on the latest master?
@Phatcat I will test and let you know later. Thank you for your work!
@Phatcat It works quite well, no crashes, thank you!
Once again, thank @kraminpouds
Example when hacks now considered as fixes. Lol. Bug in unconditional use m_creature->getVictim() in if (DoCastSpellIfCan(m_creature->getVictim(), SPELL_LIGHTNING_BOLT) == CAST_OK) after early cast when boss target can lost.
@VladimirMangos While you are right, the cmangos core is hitting random GetMap ASSERTs. Maybe thats the issue? I wasnt able to reproduce them without 500+ players online.
@VladimirMangos - I never said Gruul's Lair was fixed, but the crash is not happening, which was the issue for this; renaming and rewriting this to be an issue with the spell instead of an issue about a crash is basically the same as opening a new issue, which would have been my approach and basically also what @cyberium said here: https://github.com/cmangos/mangos-classic/pull/158#issuecomment-228391828
If you truly consider this a hackfix do not stop at this; no, you should in fact demand that we remove any failsafe since they all potentially could 'hide' a core issue. do not pretend that this is the first or something new, this is an approach I tend to stand by, so be it if you dislike me for it.
@killerwife
It's funny seeing you on @VladimirMangos s side here since you seemed to be begging for just this kind of solution not a month ago:
Yeeeaaaaah, feel free to tell me whats causing it because I have encountered this crash on multiple occasions.
What changed?
@Phatcat You can now ignore my comment. Cleary my view at project goals outdated so I resign from project owners group and I am now finally just former dev as been long time de-facto.
Well pardon me for saying this, but that went tits up.
I don't know what to say besides that that is not true at all.. And that this makes me very sad :cry:
@Phatcat, I am not very good in English so maybe you missundestood me. I not say that you ignore my comments. Cleary this is not true. I just undestand that my views at cmangos way of development possible totally outdated. I just not see now points where I can help project now. No any dramma just conclusion and requred steps.
That might not be true. Take into account that me and phatcat are mostly selftaught, (tho I have guidance from X-Savior and Laizerox and phatcat has from cyberium and cala). Before we came along, the classic and TBC branches werent getting too much love. Problem is, there isnt any real "view" on cmangos development, except the few conversations we have with the resident staff (cyberium, namreeb, xfurry, cala), and as a result we lack the people who can question our judgement in most cases, because the other guys have IRL stuff as well. (for example, resident spellcaster atm is Laizerox, top kek right :D)
TL;DR your views are not outdated, its just there are few people who actually have respectable views (I am too inexperienced to have them)
@VladimirMangos Your points are not totally outdated. Not only do I listen to all that you say but I do try to correct myself accordingly.... The thing is that Cyberium is giving me another 'directive' to follow in this case, safety over barebones (no failsaves), so I can either do as he says and upset you, or as you say and upset him. I'm starting to turn desperate here because neither of you are wrong and I agree with both of you.. If we cannot figure this out I am going to have to leave; this wil never become a me or you situation here, Vladimir. Tell me I'm an idiot and that I'm all wrong and show me how to do proper fixes... Just don't leave.. please?
Iam stiml at work so sorry for being late or short on this. Dont pannic about @VladimirMangos words. He only mean he dont want to be too much involved here. But we all are happy to see any of his comments here wenever he want. I myself would be happy to see him back. But in fact he already leaved the project. About different view, we are here to develop a server. A server is by design supposed to crash at least as possible. So wenever a solution exist to n avoid a crash we have to implement it. Sorry for reopen. Its not easy via mobile.
:unamused:
I tried three times in Gruul's Lair, every time it crashed. If you need other info, please ask me.