1 /* 2 3 Temporary implementation of a memory manager in the 4 JPEG library used in FlashPix. 5 6 7 We have define the operators FPXMalloc and FPXFree 8 9 10 */ 11 12 13 14 #ifndef FPX_MEMORY_H 15 #define FPX_MEMORY_H 16 17 #ifdef __cplusplus 18 extern "C" { 19 #endif 20 21 22 #include <stddef.h> 23 typedef void * (*MallocHookType)(size_t); 24 typedef void (*FreeHookType)(void*); 25 26 27 JPEGEXPORT 28 void * FPX_malloc(size_t); 29 JPEGEXPORT 30 void * FPX_calloc(size_t, size_t); 31 JPEGEXPORT 32 void FPX_free(void *); 33 JPEGEXPORT 34 void FPXSetMemoryHooks(MallocHookType,FreeHookType); 35 36 #ifdef __cplusplus 37 } 38 #endif 39 40 #endif 41