You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

17 lines
392 B

25 years ago
25 years ago
25 years ago
25 years ago
25 years ago
  1. // User modifiable memory allocator.
  2. #ifndef _CL_MALLOC_H
  3. #define _CL_MALLOC_H
  4. #include <cstdlib>
  5. namespace cln {
  6. // Function like malloc() which returns aligned memory of size (> 0) bytes.
  7. extern void* (*malloc_hook) (size_t size);
  8. // Function like free() which makes available for reuse such memory.
  9. extern void (*free_hook) (void* ptr);
  10. } // namespace cln
  11. #endif /* _CL_MALLOC_H */