I've been struggling with this heap error for a while and i've boiled it down to a simple issue. If i spawn more than 9 bodies, I get a heap error on application close. It's so strange. I've set up a simple test where I create a world and i create 9 bodies (storing no pointers), and delete them 5 seconds later. Then once I close the program I get the error.
"HEAP[test.win32.exe]: HEAP: Free Heap block 55bb4b0 modified at 55bb684 after it was freed
Windows has triggered a breakpoint in test.win32.exe.
This may be due to a corruption of the heap, which indicates a bug in test.win32.exe or any of the DLLs it has loaded."
But when I change the program to create 8 bodies, there is no error. What possible reason could there be for this? If its relevant I'm using box2d within cocos2d-x win32.
Any help would be appreciated!
"HEAP[test.win32.exe]: HEAP: Free Heap block 55bb4b0 modified at 55bb684 after it was freed
Windows has triggered a breakpoint in test.win32.exe.
This may be due to a corruption of the heap, which indicates a bug in test.win32.exe or any of the DLLs it has loaded."
But when I change the program to create 8 bodies, there is no error. What possible reason could there be for this? If its relevant I'm using box2d within cocos2d-x win32.
Any help would be appreciated!
