mirror of
https://github.com/devkitPro/wut.git
synced 2026-08-22 02:25:05 -05:00
coreinit: Add MEMCheckExpHeap and MEMCheckHeap (#358)
* coreinit: Add MEMCheckExpHeap and MEMCheckHeap * coreinit: Fix MEMCheckExpHeap and MEMCheckHeap functions
This commit is contained in:
@@ -31,6 +31,12 @@ typedef enum MEMExpHeapDirection
|
||||
MEM_EXP_HEAP_DIR_FROM_BOTTOM = 1,
|
||||
} MEMExpHeapDirection;
|
||||
|
||||
typedef enum MEMExpHeapCheckFlags
|
||||
{
|
||||
MEM_EXP_HEAP_CHECK_FLAGS_NONE = 0,
|
||||
MEM_EXP_HEAP_CHECK_FLAGS_LOG_ERRORS = 1,
|
||||
} MEMExpHeapCheckFlags;
|
||||
|
||||
struct MEMExpHeapBlock
|
||||
{
|
||||
uint32_t attribs;
|
||||
@@ -131,6 +137,10 @@ MEMVisitAllocatedForExpHeap(MEMHeapHandle heap,
|
||||
MEMExpHeapBlockVisitor callback,
|
||||
void *context);
|
||||
|
||||
BOOL
|
||||
MEMCheckExpHeap(MEMHeapHandle handle,
|
||||
MEMExpHeapCheckFlags mode);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -144,6 +144,12 @@ void
|
||||
MEMSetFillValForHeap(MEMHeapFillType type,
|
||||
uint32_t value);
|
||||
|
||||
/**
|
||||
* Checks the heap for corruption
|
||||
*/
|
||||
BOOL
|
||||
MEMCheckHeap(MEMHeapHandle handle);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user