Skip to content

[4.3.4] Common Server Crash related to spells with crashlog #10860

Closed
ghost opened this Issue Sep 18, 2013 · 7 comments

5 participants

@ghost
ghost commented Sep 18, 2013

This is the most common crash in the TC. Using TC last rev

CRASH ON mié sep 18 13:52:44 CEST 2013
(gdb) info program
Using the running image of child Thread 0x7fffbfbff700 (LWP 21668).
Program stopped at 0x134390f.
It stopped with signal SIGSEGV, Segmentation fault.
(gdb) shell echo -e "\nBACKTRACE\n"

BACKTRACE

(gdb) bt
#0 0x000000000134390f in SpellDestination (this=0x7fffbfbfd770, wObj=...)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:85
#1 0x00000000013447b5 in SpellCastTargets::SetDst (this=0x7fff9beb5828,
wObj=...)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:394
#2 0x00000000013499d5 in Spell::SelectImplicitTargetDestTargets (
this=0x7fff9beb5800, effIndex=EFFECT_0, targetType=...)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:1457
#3 0x000000000134753e in Spell::SelectEffectImplicitTargets (
this=0x7fff9beb5800, effIndex=EFFECT_0, targetType=...,
processedEffectMask=@0x7fffbfbfd8bc)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:879
#4 0x0000000001346cbf in Spell::SelectSpellTargets (this=0x7fff9beb5800)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:739
#5 0x000000000135096f in Spell::cast (this=0x7fff9beb5800, skipCheck=true)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:3255
#6 0x000000000134ff28 in Spell::prepare (this=0x7fff9beb5800,
targets=0x7fffbfbfdaf0, triggeredByAura=0x7fffa3774400)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:3075
#7 0x0000000000f81029 in Unit::CastSpell (this=0x7ffff2a0f000, targets=...,
spellInfo=0x7fffe81abc00, value=0x0, triggerFlags=4294967295,
castItem=0x0, triggeredByAura=0x7fffa3774400, originalCaster=89102)
at /home/repos/Trinitycore-4.3.4/src/server/game/Entities/Unit/Unit.cpp:8---Type to continue, or q to quit---shell echo -e "\nBACKTRACE FULL\n"
35
#8 0x0000000000f812c5 in Unit::CastSpell (this=0x7ffff2a0f000, victim=0x0,
spellInfo=0x7fffe81abc00, triggerFlags=4294967295, castItem=0x0,
triggeredByAura=0x7fffa3774400, originalCaster=0)
at /home/repos/Trinitycore-4.3.4/src/server/game/Entities/Unit/Unit.cpp:864
#9 0x0000000000f811a6 in Unit::CastSpell (this=0x7ffff2a0f000, victim=0x0,
spellId=19185, triggerFlags=4294967295, castItem=0x0,
triggeredByAura=0x7fffa3774400, originalCaster=0)
at /home/repos/Trinitycore-4.3.4/src/server/game/Entities/Unit/Unit.cpp:852
#10 0x0000000000f81096 in Unit::CastSpell (this=0x7ffff2a0f000, victim=0x0,
spellId=19185, triggered=true, castItem=0x0,
triggeredByAura=0x7fffa3774400, originalCaster=0)
at /home/repos/Trinitycore-4.3.4/src/server/game/Entities/Unit/Unit.cpp:840
#11 0x0000000000f9744f in Unit::HandleProcTriggerSpell (this=0x7ffff2a0f000,
victim=0x0, damage=0, triggeredByAura=0x7fffa3774400,
procSpell=0x7fffe3d03000, procFlags=2097152, procEx=67108865, cooldown=0)
at /home/repos/Trinitycore-4.3.4/src/server/game/Entities/Unit/Unit.cpp:7130
#12 0x0000000000faa2ad in Unit::ProcDamageAndSpellFor (this=0x7ffff2a0f000,
isVictim=false, target=0x0, procFlag=2097152, procExtra=67108865,
---Type to continue, or q to quit---bt full
attType=BASE_ATTACK, procSpell=0x7fffe3d03000, damage=0, procAura=0x0)
at /home/repos/Trinitycore-4.3.4/src/server/game/Entities/Unit/Unit.cpp:12381
#13 0x0000000000f8fe99 in Unit::ProcDamageAndSpell (this=0x7ffff2a0f000,
victim=0x0, procAttacker=2097152, procVictim=0, procExtra=67108865,
amount=0, attType=BASE_ATTACK, procSpell=0x7fffe3d03000, procAura=0x0)
at /home/repos/Trinitycore-4.3.4/src/server/game/Entities/Unit/Unit.cpp:4728
#14 0x00000000013516e9 in Spell::_handle_immediate_phase (this=0x7fff9beb5100)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:3522
#15 0x0000000001351036 in Spell::handle_immediate (this=0x7fff9beb5100)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:3391
#16 0x0000000001350cdd in Spell::cast (this=0x7fff9beb5100, skipCheck=true)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:3334
#17 0x000000000134ff28 in Spell::prepare (this=0x7fff9beb5100,
targets=0x7fffbfbfe330, triggeredByAura=0x0)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:3075
#18 0x0000000000f81029 in Unit::CastSpell (this=0x7fff99ff7000, targets=...,
spellInfo=0x7fffe3d03000, value=0x7fffbfbfe3d0, triggerFlags=4294967295,
castItem=0x0, triggeredByAura=0x0, originalCaster=89102)
at /home/repos/Trinitycore-4.3.4/src/server/game/Entities/Unit/Unit.cpp:835
#19 0x000000000149a9c6 in Spell::EffectTriggerSpell (this=0x7fff9beb3c00,
---Type to continue, or q to quit---shell echo -e "\nTHREADS\n"
effIndex=EFFECT_1)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/SpellEffects.cpp:814
#20 0x00000000013560a6 in Spell::HandleEffects (this=0x7fff9beb3c00,
pUnitTarget=0x0, pItemTarget=0x0, pGOTarget=0x0, i=1,
mode=SPELL_EFFECT_HANDLE_LAUNCH)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:4778
#21 0x000000000135da00 in Spell::HandleLaunchPhase (this=0x7fff9beb3c00)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:6746
#22 0x0000000001350bbd in Spell::cast (this=0x7fff9beb3c00, skipCheck=true)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:3311
#23 0x000000000134ff28 in Spell::prepare (this=0x7fff9beb3c00,
targets=0x7fffbfbfe730, triggeredByAura=0x0)
at /home/repos/Trinitycore-4.3.4/src/server/game/Spells/Spell.cpp:3075
#24 0x0000000000f81029 in Unit::CastSpell (this=0x7fff99ff7000, targets=...,
spellInfo=0x7fffe92f8400, value=0x0, triggerFlags=4294967295,
castItem=0x0, triggeredByAura=0x0, originalCaster=89102)
at /home/repos/Trinitycore-4.3.4/src/server/game/Entities/Unit/Unit.cpp:835
#25 0x0000000000f812c5 in Unit::CastSpell (this=0x7fff99ff7000,
victim=0x7fffa2415000, spellInfo=0x7fffe92f8400, triggerFlags=4294967295,
castItem=0x0, triggeredByAura=0x0, originalCaster=89102)
at /home/repos/Trinitycore-4.3.4/src/server/game/Entities/Unit/Unit.cpp:8---Type to continue, or q to quit---info threads
64
#26 0x0000000000f81212 in Unit::CastSpell (this=0x7fff99ff7000,
victim=0x7fffa2415000, spellInfo=0x7fffe92f8400, triggered=true,
castItem=0x0, triggeredByAura=0x0, originalCaster=89102)
at /home/repos/Trinitycore-4.3.4/src/server/game/Entities/Unit/Unit.cpp:857
#27 0x0000000000ff9db8 in GameObject::CastSpell (this=0x7fff9a7d6700,
target=0x7fffa2415000, spellId=45145)
at /home/repos/Trinitycore-4.3.4/src/server/game/Entities/GameObject/GameObject.cpp:1704
#28 0x0000000000ff5d26 in GameObject::Update (this=0x7fff9a7d6700, diff=100)
at /home/repos/Trinitycore-4.3.4/src/server/game/Entities/GameObject/GameObject.cpp:478
#29 0x000000000118c39f in Trinity::ObjectUpdater::Visit (
this=0x7fffbfbfed30, m=...)
at /home/repos/Trinitycore-4.3.4/src/server/game/Grids/Notifiers/GridNotifiers.cpp:329
#30 0x0000000001240f67 in VisitorHelper (
v=..., c=...)
at /home/repos/Trinitycore-4.3.4/src/server/shared/Dynamic/TypeContainerVisitor.h:64
#31 0x00000000012406e9 in VisitorHelper to continue, or q to quit---shell echo -e "\nTHREADS BACKTRACE\n"
peNull> > > > > (v=..., c=...)
at /home/repos/Trinitycore-4.3.4/src/server/shared/Dynamic/TypeContainerVisitor.h:70
#32 0x000000000123ffa7 in VisitorHelper > > > > > (v=..., c=...)
at /home/repos/Trinitycore-4.3.4/src/server/shared/Dynamic/TypeContainerVisitor.h:94
#33 0x000000000123f7f0 in TypeContainerVisitor > > > > > >::Visit (
this=0x7fffbfbfed20, c=...)
at /home/repos/Trinitycore-4.3.4/src/server/shared/Dynamic/TypeContainerVisitor.h:105
#34 0x000000000123e271 in Grid > > >, TypeList > > > > >::VisitTrinity::ObjectUpdater (this=0x7fffa35d2a58,
visitor=...)
at /home/repos/Trinitycore-4.3.4/src/server/game/Grids/Grid.h:91
#35 0x000000000123c549 in NGrid<8u, Player, TypeList > > >, TypeList to continue, or q to quit---thread apply all bt full
TypeNull> > > > > >::VisitGrid > > > > > (this=0x7fffa35d0000, x=3, y=0, visitor=...)
at /home/repos/Trinitycore-4.3.4/src/server/game/Grids/NGrid.h:157
#36 0x0000000001238c50 in Map::Visit > > > > > > (this=0x7fffd5fc0000, cell=...,
visitor=...)
at /home/repos/Trinitycore-4.3.4/src/server/game/Maps/Map.h:695
#37 0x000000000122c839 in Map::VisitNearbyCellsOf (this=0x7fffd5fc0000,
obj=0x7ffff2a0f000, gridVisitor=..., worldVisitor=...)
at /home/repos/Trinitycore-4.3.4/src/server/game/Maps/Map.cpp:511
#38 0x000000000122cb26 in Map::Update (this=0x7fffd5fc0000, t_diff=100)
at /home/repos/Trinitycore-4.3.4/src/server/game/Maps/Map.cpp:553
#39 0x000000000148a73e in MapUpdateRequest::call (this=0x7fff9abe6400)
at /home/repos/Trinitycore-4.3.4/src/server/game/Maps/MapUpdater.cpp:54
#40 0x000000000151d391 in DelayExecutor::svc (this=0x7ffff4905340)
at /home/repos/Trinitycore-4.3.4/src/server/shared/Threading/DelayExecutor.cpp:52
#41 0x00007ffff76f0d77 in ACE_Task_Base::svc_run (args=)
at ../../ace/Task.cpp:271
#42 0x00007ffff76f2122 in ACE_Thread_Adapter::invoke_i (
this=) at ../../ace/Thread_Adapter.cpp:161
#43 0x00007ffff76f21a1 in ACE_Thread_Adapter::invoke (this=0x7fffcb9b5740)
at ../../ace/Thread_Adapter.cpp:96
#44 0x00007ffff67338ca in start_thread () from /lib/libpthread.so.0
#45 0x00007ffff5ceeb6d in clone () from /lib/libc.so.6
#46 0x0000000000000000 in ?? ()

@jackpoz
TrinityCore member
jackpoz commented Sep 18, 2013

Please state the commit hash, there's no such thing as "TC last rev"

@ghost
ghost commented Sep 18, 2013

Sry I supposed understand that last commit e740332, just updated few hours ago and crashed, just now again crashed same crashlog

@Faq
Faq commented Sep 18, 2013

+never post log directly

@zorix
zorix commented Sep 18, 2013

Victim is NULL in Unit::HandleProcTriggerSpell
Crash fix (tested):
http://www.trinitycore.org/f/pastebin/jikxig393kb
It will fix #10853 too

@Shauren
TrinityCore member
Shauren commented Sep 19, 2013

That fix is not correct, in target-dest-target mode, the unit is REQUIRED - need add check at proc level

@zorix
zorix commented Sep 19, 2013

http://www.trinitycore.org/f/pastebin/lfi8221bp0n/
With this fix talent work perfectly without any other changes and maybe it will fix some other issue because it was triggering spell with different primal target but when some spells must be casted on the caster blizz using target type TARGET_UNIT_CASTER so it shouldn't broke any spell.

This was referenced Sep 20, 2013
@ghost
ghost commented Sep 29, 2013

Hi zorix, after lot of testing with first fix there weren't more crashes, but with second still was bug, so for now let the 1st fix: http://www.trinitycore.org/f/pastebin/jikxig393kb

I could reproduce, for example with an ice trap from hunter attacking lvl 1 snakes, bunnies, rats, and all these random and useless world npcs.

Ty for your effort

@zorix zorix added a commit to zorix/TrinityCore that referenced this issue Jan 27, 2014
@zorix zorix Core/Spell:
Triggered spells now will be cast on the primal target instead of on caster

Close #10853
Close #10860
e9b7bb0
@jackpoz jackpoz changed the title from Common Server Crash related to spells with crashlog to [4.3.4] Common Server Crash related to spells with crashlog Jun 26, 2014
@Subv Subv closed this in #10887 Jul 8, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.