the game where you go into mines and start crafting! but for consoles (forked directly from smartcmd's github)
at master 30 lines 939 B view raw
1// ================================================================================================================================= 2// This sample demonstrates how to use the auto-hooking functionality of HeapInspector. On PlayStation 3, this uses link-time 3// malloc/realloc/free overloading. On PC it uses the mhook API, which will hook into the very low-level HeapAlloc, HeapRealloc 4// and HeapFree functions. This will cause any allocations in your application to be caught. 5// 6// NOTE: the platform specific hooking calls can be found in the Main<platform>.cpp. 7// ================================================================================================================================= 8 9#include <stdlib.h> 10 11void Wait(int a_MilliSeconds); 12 13void RunHeapInspectorServer() 14{ 15 while (1) 16 { 17 void* mem1; 18 void* memB; 19 20 mem1 = malloc(16); 21 memB = malloc(1024); 22 23 Wait(100); 24 25 free(mem1); 26 free(memB); 27 28 Wait(100); 29 } 30}