c++ - Why does MIcroQuill Smartheap throw "mem_bad_pointer" errors after I embed perl? -


I embed Pearl into a C ++ application that uses. Even though I compile Pearl to use my own malloc or system, I get a group of errors mem___bad_pointer dialog. It seems that when I click "OK" and Ignore errors, I work fine, but obviously I really need to solve the problem.

Do I need to compile smarthap in my Pearl build? Is this also possible?

Below can find a page about mem__bad_pointer, but I am not close to solving the problem. I do not know how Pearl and SmartShare are conflicting with each other or how. Any indicators were appreciated.

  • Other than the SmartHeap, the pointer was assigned to other memory managers, such as from any other DLL or EXE, or compiler runtime libraries. Check your map file to see if linking to malloc, _fmalloc / farmalloc, or operator's SmartHeap version.
  • The indicator is "wild" (raw), allocated on the stack (local variable), or otherwise is invalid.
  • The pointer was already free. If SmartHeap has released the page in which the pointer was originally allocated, SmartHeap would not be able to find that it is double free. However, Smarthap will report invalid pointer. Use dbgMemDeferFreeing to catch this type of bug.
  • The indicator has increased or decreased since the time of allocation.
  • For 16-bit x86, the pointer was thrown after the pass point allocation, in which case the segment portion of the indicator is lost.
  • The memory pool in which the pointer was allocated has been released, or SmartHeap has been unregistered from the job.
  • The point at which allocated was completed (see section B.4).

It is difficult to debug the problem without seeing the code. Perhaps you have smartup and regular memory Managers are allocating memory using both. This may be the reason when you allocate memory in the DLL building without a smart pile.

Depending on your code, allocation may be fine and you can write out all the stored memory area.


Comments