File: cl_malloc.h

package info (click to toggle)
cln 0.98-7.1
  • links: PTS
  • area: main
  • in suites: slink
  • size: 12,188 kB
  • ctags: 15,282
  • sloc: cpp: 71,545; ansic: 12,015; asm: 8,431; sh: 3,159; makefile: 886; lisp: 64
file content (17 lines) | stat: -rw-r--r-- 422 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// User modifiable memory allocator.

#ifndef _CL_MALLOC_H
#define _CL_MALLOC_H

#ifdef HAVE_STDLIB_H
  #include <stdlib.h>
#else
  #include <sys/types.h>
#endif

// Function like malloc() which returns aligned memory of size (> 0) bytes.
extern void* (*cl_malloc_hook) (size_t size);
// Function like free() which makes available for reuse such memory.
extern void (*cl_free_hook) (void* ptr);

#endif /* _CL_MALLOC_H */