Jump to content

.npc delitem crash [9750]


Guest wow4

Recommended Posts

try to delete a item from a npc with this command you get this

Revision: * * 9750 *
Date 17:4:2010. Time 18:22 
//=====================================================
*** Hardware ***
Processor: AMD Phenom(tm) II X4 955 Processor
Number Of Processors: 4
Physical Memory: 4193784 KB (Available: 2053536 KB)
Commit Charge Limit: 8385668 KB

*** Operation System ***
Windows Vista or Windows Server 2008 Professional (Version 6.1, Build 7600)

//=====================================================
Exception code: C0000005 ACCESS_VIOLATION
Fault address:  000000014010942E 01:000000000010842E C:\\Users\\..\\Server\\Realm_2\\World_server\\mangosd.exe

Registers:
RAX:000000000000CB34
RBX:0000000009AB94B0
RCX:40200000BF15D400
RDX:000007FFE8E21508
RSI:000007FFF1114E50
RDI:000000014007CED0
R8: 0000000019999999
R9: 0000000072F4A820
R10:0000000008DDF540
R11:0000000000000000
R12:0000000000000000
R13:0000000000000000
R14:0000000000000000
R15:0000000008DDEE70
CS:RIP:0033:000000014010942E
SS:RSP:002B:0000000008DDF430  RBP:00000000
DS:002B  ES:002B  FS:0053  GS:002B
Flags:00010202

Call stack:
Address   Frame     Function      SourceFile
000000014010942E  0000000008DDF4E0  VendorItemData::RemoveItem+BE  c:\\users\\..\\mangos\\src\\game\\creature.cpp line 65
000000014024C617  0000000008DDF590  ObjectMgr::RemoveVendorItem+B7  c:\\users\\..\\mangos\\src\\game\\objectmgr.cpp line 8277
000000014054C5E1  0000000008DE1630  ChatHandler::HandleNpcDelVendorItemCommand+121  c:\\users\\..\\mangos\\src\\game\\level2.cpp line 1175
000000014021D170  0000000008DE17F0  ChatHandler::ExecuteCommandInTable+410  c:\\users\\..\\mangos\\src\\game\\chat.cpp line 896
000000014021CF15  0000000008DE19B0  ChatHandler::ExecuteCommandInTable+1B5  c:\\users\\..\\mangos\\src\\game\\chat.cpp line 876
000000014021DAAA  0000000008DE3A60  ChatHandler::ParseCommands+1FA  c:\\users\\..\\mangos\\src\\game\\chat.cpp line 1016
0000000140626409  0000000008DEF830  WorldSession::HandleMessagechatOpcode+FE9  c:\\users\\..\\mangos\\src\\game\\chathandler.cpp line 273
00000001402DD33D  0000000008DEFB10  WorldSession::Update+13D  c:\\users\\..\\mangos\\src\\game\\worldsession.cpp line 189
00000001402F128C  0000000008DEFC50  World::UpdateSessions+14C  c:\\users\\..\\mangos\\src\\game\\world.cpp line 1831
00000001402EF58C  0000000008DEFE00  World::Update+34C  c:\\users\\..\\mangos\\src\\game\\world.cpp line 1388
000000014006C8B5  0000000008DEFE40  WorldRunnable::run+A5  c:\\users\\..\\mangos\\src\\mangosd\\worldrunnable.cpp line 61
000000014007CEF3  0000000008DEFEB0  ACE_Based::Thread::ThreadTask+23  c:\\users\\..\\mangos\\src\\shared\\threading.cpp line 190
000007FEF171157B  0000000008DEFEF0  ?invoke@ACE_OS_Thread_Adapter@@UEAAKXZ+5B
0000000072ED2FDF  0000000008DEFF20  _endthreadex+47
0000000072ED3080  0000000008DEFF50  _endthreadex+E8
0000000076E7F56D  0000000008DEFF80  BaseThreadInitThunk+D
0000000076FB3281  0000000008DEFFD0  RtlUserThreadStart+21

Call stack:
Address   Frame     Function      SourceFile
0000000076FCFEFA  000000000042F980  NtWaitForSingleObject+A
000007FEFD0710AC  000000000042FA20  WaitForSingleObjectEx+9C
000007FEF16BB69A  000000000042FA50  ?thr_join@ACE_OS@@YAHPEAXPEAK@Z+2A
000007FEF173E863  000000000042FAD0  ?wait_task@ACE_Thread_Manager@@QEAAHPEAVACE_Task_Base@@@Z+243
000000014030DDA3  000000000042FB10  WorldSocketMgr::Wait+63  c:\\users\\..\\mangos\\src\\game\\worldsocketmgr.cpp line 316
000000014003BE55  000000000042FEE0  Master::Run+9B5  c:\\users\\..\\mangos\\src\\mangosd\\master.cpp line 325
000000014003A87D  000000000042FF20  main+42D  c:\\users\\..\\mangos\\src\\mangosd\\main.cpp line 180
000000014006D386  000000000042FF50  __tmainCRTStartup+11A  f:\\dd\\vctools\\crt_bld\\self_64_amd64\\crt\\src\\crtexe.c line 586
0000000076E7F56D  000000000042FF80  BaseThreadInitThunk+D
0000000076FB3281  000000000042FFD0  RtlUserThreadStart+21

Call stack:
Address   Frame     Function      SourceFile
0000000076FD046A  000000000341FCB0  ZwWaitForMultipleObjects+A
0000000076F99BD7  000000000341FF50  EtwTraceMessageVa+E07
0000000076E7F56D  000000000341FF80  BaseThreadInitThunk+D
0000000076FB3281  000000000341FFD0  RtlUserThreadStart+21

Call stack:
Address   Frame     Function      SourceFile
0000000076FD01FA  000000000381FC60  NtDelayExecution+A
000007FEFD071203  000000000381FD00  SleepEx+B3
000000014007D159  000000000381FD50  ACE_Based::Thread::Sleep+39  c:\\users\\..\\mangos\\src\\shared\\threading.cpp line 238
0000000140081D4F  000000000381FE40  SqlDelayThread::run+6F  c:\\users\\..\\mangos\\src\\shared\\database\\sqldelaythread.cpp line 45
000000014007CEF3  000000000381FEB0  ACE_Based::Thread::ThreadTask+23  c:\\users\\..\\mangos\\src\\shared\\threading.cpp line 190
000007FEF171157B  000000000381FEF0  ?invoke@ACE_OS_Thread_Adapter@@UEAAKXZ+5B
0000000072ED2FDF  000000000381FF20  _endthreadex+47
0000000072ED3080  000000000381FF50  _endthreadex+E8
0000000076E7F56D  000000000381FF80  BaseThreadInitThunk+D
0000000076FB3281  000000000381FFD0  RtlUserThreadStart+21

Call stack:
Address   Frame     Function      SourceFile
0000000076FD01FA  0000000003C1FC60  NtDelayExecution+A
000007FEFD071203  0000000003C1FD00  SleepEx+B3
000000014007D159  0000000003C1FD50  ACE_Based::Thread::Sleep+39  c:\\users\\..\\mangos\\src\\shared\\threading.cpp line 238
0000000140081D4F  0000000003C1FE40  SqlDelayThread::run+6F  c:\\users\\..\\mangos\\src\\shared\\database\\sqldelaythread.cpp line 45
000000014007CEF3  0000000003C1FEB0  ACE_Based::Thread::ThreadTask+23  c:\\users\\..\\mangos\\src\\shared\\threading.cpp line 190
000007FEF171157B  0000000003C1FEF0  ?invoke@ACE_OS_Thread_Adapter@@UEAAKXZ+5B
0000000072ED2FDF  0000000003C1FF20  _endthreadex+47
0000000072ED3080  0000000003C1FF50  _endthreadex+E8
0000000076E7F56D  0000000003C1FF80  BaseThreadInitThunk+D
0000000076FB3281  0000000003C1FFD0  RtlUserThreadStart+21

Call stack:
Address   Frame     Function      SourceFile
0000000076FD01FA  000000000401FC60  NtDelayExecution+A
000007FEFD071203  000000000401FD00  SleepEx+B3
000000014007D159  000000000401FD50  ACE_Based::Thread::Sleep+39  c:\\users\\..\\mangos\\src\\shared\\threading.cpp line 238
0000000140081D4F  000000000401FE40  SqlDelayThread::run+6F  c:\\users\\..\\mangos\\src\\shared\\database\\sqldelaythread.cpp line 45
000000014007CEF3  000000000401FEB0  ACE_Based::Thread::ThreadTask+23  c:\\users\\..\\mangos\\src\\shared\\threading.cpp line 190
000007FEF171157B  000000000401FEF0  ?invoke@ACE_OS_Thread_Adapter@@UEAAKXZ+5B
0000000072ED2FDF  000000000401FF20  _endthreadex+47
0000000072ED3080  000000000401FF50  _endthreadex+E8
0000000076E7F56D  000000000401FF80  BaseThreadInitThunk+D
0000000076FB3281  000000000401FFD0  RtlUserThreadStart+21

Call stack:
Address   Frame     Function      SourceFile
0000000076FD0B8A  0000000008DDCD40  ZwGetContextThread+A
0000000076E644FA  0000000008DDCD70  GetThreadContext+A
000000014006B159  0000000008DDD2B0  WheatyExceptionReport::PrintTracesForAllThreads+C9  c:\\users\\..\\mangos\\src\\shared\\wheatyexceptionreport.cpp line 370
000000014006B526  0000000008DDE320  WheatyExceptionReport::GenerateExceptionReport+396  c:\\users\\..\\mangos\\src\\shared\\wheatyexceptionreport.cpp line 468
000000014006A7BA  0000000008DDE5D0  WheatyExceptionReport::WheatyUnhandledExceptionFilter+18A  c:\\users\\..\\mangos\\src\\shared\\wheatyexceptionreport.cpp line 109
0000000076EF9380  0000000008DDE6B0  UnhandledExceptionFilter+160
000000007701573C  0000000008DDE6E0  MD5Final+1DEC
0000000076F95148  0000000008DDE750  __C_specific_handler+9C
0000000076FB554D  0000000008DDE780  RtlCompareUnicodeString+7D
0000000076F95D1C  0000000008DDEE60  RtlTimeToSecondsSince1970+62C
0000000076FCFE48  0000000008DDF420  KiUserExceptionDispatcher+2E
000000014010942E  0000000008DDF4E0  VendorItemData::RemoveItem+BE  c:\\users\\..\\mangos\\src\\game\\creature.cpp line 65
000000014024C617  0000000008DDF590  ObjectMgr::RemoveVendorItem+B7  c:\\users\\..\\mangos\\src\\game\\objectmgr.cpp line 8277
000000014054C5E1  0000000008DE1630  ChatHandler::HandleNpcDelVendorItemCommand+121  c:\\users\\..\\mangos\\src\\game\\level2.cpp line 1175
000000014021D170  0000000008DE17F0  ChatHandler::ExecuteCommandInTable+410  c:\\users\\..\\mangos\\src\\game\\chat.cpp line 896
000000014021CF15  0000000008DE19B0  ChatHandler::ExecuteCommandInTable+1B5  c:\\users\\..\\mangos\\src\\game\\chat.cpp line 876
000000014021DAAA  0000000008DE3A60  ChatHandler::ParseCommands+1FA  c:\\users\\..\\mangos\\src\\game\\chat.cpp line 1016
0000000140626409  0000000008DEF830  WorldSession::HandleMessagechatOpcode+FE9  c:\\users\\..\\mangos\\src\\game\\chathandler.cpp line 273
00000001402DD33D  0000000008DEFB10  WorldSession::Update+13D  c:\\users\\..\\mangos\\src\\game\\worldsession.cpp line 189
00000001402F128C  0000000008DEFC50  World::UpdateSessions+14C  c:\\users\\..\\mangos\\src\\game\\world.cpp line 1831
00000001402EF58C  0000000008DEFE00  World::Update+34C  c:\\users\\..\\mangos\\src\\game\\world.cpp line 1388
000000014006C8B5  0000000008DEFE40  WorldRunnable::run+A5  c:\\users\\..\\mangos\\src\\mangosd\\worldrunnable.cpp line 61
000000014007CEF3  0000000008DEFEB0  ACE_Based::Thread::ThreadTask+23  c:\\users\\..\\mangos\\src\\shared\\threading.cpp line 190
000007FEF171157B  0000000008DEFEF0  ?invoke@ACE_OS_Thread_Adapter@@UEAAKXZ+5B
0000000072ED2FDF  0000000008DEFF20  _endthreadex+47
0000000072ED3080  0000000008DEFF50  _endthreadex+E8
0000000076E7F56D  0000000008DEFF80  BaseThreadInitThunk+D
0000000076FB3281  0000000008DEFFD0  RtlUserThreadStart+21

Call stack:
Address   Frame     Function      SourceFile
0000000076FD00DA  00000000091EF7C0  ZwRequestWaitReplyPort+A
0000000076E82B08  00000000091EF7F0  GetConsoleMode+F8
0000000076EB5601  00000000091EF940  VerifyConsoleIoHandle+281
0000000076ECA922  00000000091EFA20  ReadConsoleA+B2
0000000076E99934  00000000091EFA60  GetEnvironmentStringsA+5AB8
0000000072F1DC36  00000000091EFB00  realloc+72A
0000000072F1E29D  00000000091EFB60  _read+10D
0000000072EDE7E3  00000000091EFBA0  _filbuf+8F
0000000072EDDC6C  00000000091EFC10  fgets+198
0000000140014C39  00000000091EFE40  CliRunnable::run+B9  c:\\users\\..\\mangos\\src\\mangosd\\clirunnable.cpp line 327
000000014007CEF3  00000000091EFEB0  ACE_Based::Thread::ThreadTask+23  c:\\users\\..\\mangos\\src\\shared\\threading.cpp line 190
000007FEF171157B  00000000091EFEF0  ?invoke@ACE_OS_Thread_Adapter@@UEAAKXZ+5B
0000000072ED2FDF  00000000091EFF20  _endthreadex+47
0000000072ED3080  00000000091EFF50  _endthreadex+E8
0000000076E7F56D  00000000091EFF80  BaseThreadInitThunk+D
0000000076FB3281  00000000091EFFD0  RtlUserThreadStart+21

Call stack:
Address   Frame     Function      SourceFile
0000000076FCFEFA  000000000A36F880  NtWaitForSingleObject+A
000007FEFC713978  000000000A36F900  0001:0000000000002978 C:\\Windows\\system32\\MSWSOCK.dll
000007FEFC7206B6  000000000A36FAA0  WSPStartup+7CD6
000007FEFD3372BC  000000000A36FAE0  select+15C
000007FEFD33723D  000000000A36FBE0  select+DD
000007FEF16C82A2  000000000A36FC60  ?wait_for_multiple_events@?$ACE_Select_Reactor_T@V?$ACE_Reactor_Token_T@VACE_Token@@@@@@MEAAHAEAVACE_Select_Reactor_Handle_Set@@PEAVACE_Time_Value@@@Z+132
000007FEF1740D30  000000000A36FCD0  ?handle_events@ACE_TP_Reactor@@UEAAHPEAVACE_Time_Value@@@Z+A0
000007FEF171E3ED  000000000A36FD00  ?run_reactor_event_loop@ACE_Reactor@@QEAAHAEAVACE_Time_Value@@P6AHPEAV1@@Z@Z+4D
000000014030D6D7  000000000A36FE40  ReactorRunnable::svc+77  c:\\users\\..\\mangos\\src\\game\\worldsocketmgr.cpp line 167
000007FEF173A0F1  000000000A36FE70  ?svc_run@ACE_Task_Base@@SAKPEAX@Z+41
000007FEF173A6AB  000000000A36FEB0  ?invoke_i@ACE_Thread_Adapter@@EEAAKXZ+4B
000007FEF173A7D1  000000000A36FEF0  ?invoke@ACE_Thread_Adapter@@UEAAKXZ+71
0000000072ED2FDF  000000000A36FF20  _endthreadex+47
0000000072ED3080  000000000A36FF50  _endthreadex+E8
0000000076E7F56D  000000000A36FF80  BaseThreadInitThunk+D
0000000076FB3281  000000000A36FFD0  RtlUserThreadStart+21

Call stack:
Address   Frame     Function      SourceFile
0000000076FCFEFA  000000000A76F880  NtWaitForSingleObject+A
000007FEFC713978  000000000A76F900  0001:0000000000002978 C:\\Windows\\system32\\MSWSOCK.dll
000007FEFC7206B6  000000000A76FAA0  WSPStartup+7CD6
000007FEFD3372BC  000000000A76FAE0  select+15C
000007FEFD33723D  000000000A76FBE0  select+DD
000007FEF16C82A2  000000000A76FC60  ?wait_for_multiple_events@?$ACE_Select_Reactor_T@V?$ACE_Reactor_Token_T@VACE_Token@@@@@@MEAAHAEAVACE_Select_Reactor_Handle_Set@@PEAVACE_Time_Value@@@Z+132
000007FEF1740D30  000000000A76FCD0  ?handle_events@ACE_TP_Reactor@@UEAAHPEAVACE_Time_Value@@@Z+A0
000007FEF171E3ED  000000000A76FD00  ?run_reactor_event_loop@ACE_Reactor@@QEAAHAEAVACE_Time_Value@@P6AHPEAV1@@Z@Z+4D
000000014030D6D7  000000000A76FE40  ReactorRunnable::svc+77  c:\\users\\..\\mangos\\src\\game\\worldsocketmgr.cpp line 167
000007FEF173A0F1  000000000A76FE70  ?svc_run@ACE_Task_Base@@SAKPEAX@Z+41
000007FEF173A6AB  000000000A76FEB0  ?invoke_i@ACE_Thread_Adapter@@EEAAKXZ+4B
000007FEF173A7D1  000000000A76FEF0  ?invoke@ACE_Thread_Adapter@@UEAAKXZ+71
0000000072ED2FDF  000000000A76FF20  _endthreadex+47
0000000072ED3080  000000000A76FF50  _endthreadex+E8
0000000076E7F56D  000000000A76FF80  BaseThreadInitThunk+D
0000000076FB3281  000000000A76FFD0  RtlUserThreadStart+21

Call stack:
Address   Frame     Function      SourceFile
0000000076FD17BA  000000000B36FC50  ZwWaitForWorkViaWorkerFactory+A
0000000076F9914B  000000000B36FF50  EtwTraceMessageVa+37B
0000000076E7F56D  000000000B36FF80  BaseThreadInitThunk+D
0000000076FB3281  000000000B36FFD0  RtlUserThreadStart+21
========================
Local Variables And Parameters

Call stack:
Address   Frame     Function      SourceFile
000000014010942E  0000000008DDF4E0  VendorItemData::RemoveItem+BE  c:\\users\\..\\mangos\\src\\game\\creature.cpp line 65

Link to comment
Share on other sites

try with

diff --git a/src/game/Creature.cpp b/src/game/Creature.cpp
index 816a91d..4fdaa4b 100644
--- a/src/game/Creature.cpp
+++ b/src/game/Creature.cpp
@@ -59,14 +59,17 @@ TrainerSpell const* TrainerSpellData::Find(uint32 spell_id) const
bool VendorItemData::RemoveItem( uint32 item_id )
{
    bool found = false;
-    for(VendorItemList::iterator i = m_items.begin(); i != m_items.end(); ++i )
+    for(VendorItemList::iterator i = m_items.begin(); i != m_items.end(); )
    {
        // can have many examples
        if((*i)->item == item_id)
        {
            m_items.erase(i);
            found = true;
+            i = m_items.begin();
        }
+        else
+            ++i;
    }

    return found;

Link to comment
Share on other sites

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use