Heap question

Windows specific forum
wilbert
PureBasic Expert
PureBasic Expert
Posts: 3943
Joined: Sun Aug 08, 2004 5:21 am
Location: Netherlands

Heap question

Post by wilbert »

I have two subroutines that are executed almost right after eachother.
Both subroutines allocate a little memory (a few KB) with _HeapAlloc@12 and free it again with _HeapFree@12.

For some reason it doens't work. I tried using _PB_AllocateMemory@4 and _PB_FreeMemory@4 instead but that also didn't work.

When I use HeapAlloc / HeapFree in one routine and PB_AllocateMemory / PB_FreeMemory in the other it does work :?:
Also when I disable one of the two routines, the other one functions fine.

I don't understand what I might be doing wrong.
Does anyone have an idea ?