2010-5-17
在debug模式下运行平台,启动初,output窗口就输出如下信息:
First-chance exception in hotfoxd.exe (KERNEL32.DLL): 0x000006EF: (no name).
经查,发现是hotfox.cpp的int Hotfox_Deamon::svc (void)的以下代码造成的
if (report_status (SERVICE_RUNNING) == 0)///<运行该行代码,会造成first-chancne exception
reactor ()->owner (ACE_Thread::self ());
跟进report_status的实现(ACE的NT_Service.cpp单元),异常报出在以下代码,
retval = SetServiceStatus (this->svc_handle_,
&this->svc_status_) ? 0 : -1;
this->svc_handle_为NULL。
该问题不是核心问题,暂缓解决。
单据调试CDAPPlugin::GetOrg时,弹出Disassembly窗口,调用栈为:
DAP! @ILT+3175(?Add@COrgHelper@@SAHPAUORGINFO@@@Z) address 0x03131c2b
CDAPPlugin::GetOrg(unsigned int 50001, unsigned char 1) line 90 + 17 bytes
CRTOPlugin::HandleSend(umxns::CUMXApp * 0x00ee52d0, CWrappedMsg<umxns::CUMXApp> * * 0x0b9cfe48) line 337 + 27 bytes
HTX_Msg_Sender::handle_message_block(ACE_Message_Block * 0x00ee2850) line 956 + 49 bytes
HTX_Task_Base::svc() line 103 + 17 bytes
ACE_Task_Base::svc_run(void * 0x00ec7bf0) line 203 + 11 bytes
ACE_Thread_Adapter::invoke_i() line 150 + 7 bytes
ACE_Thread_Adapter::invoke() line 93 + 11 bytes
ace_thread_adapter(void * 0x00ec3b80) line 131 + 10 bytes
MSVCRTD! 1020c323()
KERNEL32! 7c82482f()
如果直接运行,就不会出这个问题。这个现象也解释不清楚。
今天晚上10:00左右,把昨天修改的dap代码上上去,再观察。如果再出问题,则把这些dap代码移到rto插件。如果再出问题???
如果不再出问题,则问题范围就得到很大的缩小。