还是boudcheck检测出的,但是不知道意思:
1 Allocation Conflict: Attempting to call free on 0x02E532B0; pointer was allocated by global_operator_new.
  File: Safemon.dll2 Calling SuspendThread() while executing under Error Detection may lead to spurious deadlocks.
  Function              File            Line
  CreateThread      thrdcore.cpp       564
  AfxBeginThread     thrdcore.cpp       3103 Bad Pointer: 0x04F3BBD4 passed to VariantClear, argument 1.
这个错误提示的代码在这里:inline _variant_t::~_variant_t() throw()
{
    ::VariantClear(this);//指向这一行
}4 Implied Free: Suballocated block at 0x03661000 (12288) has been freed by call to UnmapViewOfFile for parent block at 0x03660000 (4194304).
  Function                File               Line
  AddModule         allocate.cpp      341
  AtlTraceRegister atldebugapi.cpp       41

解决方案 »

  1.   

    内存泄露?那你得好好检查一下了。
    查找new 对应的 delete
      

  2.   


    释放的时候加个判断,释放之后赋值为NULL,如:if (p)
    {
       delete p;
       p = NULL;
    }
      

  3.   

    UnmapViewOfFile 
    已经释放了,内存映像文件
      

  4.   

    问题是只有第三处错误是数据库相关的操作,其余的都不是我的代码,而是MFC自己的头文件呀。