source: abuse/trunk/src/imlib/include/jmalloc.hpp @ 39

Last change on this file since 39 was 39, checked in by Sam Hocevar, 15 years ago
  • Fix almost 2,000 warnings by using proper "const" keywords where needed.
File size: 590 bytes
Line 
1#ifndef __jmalloc_hpp_
2#define __jmalloc_hpp_
3
4
5#include <stdlib.h>
6
7#ifdef MANAGE_MEM
8enum {ALLOC_SPACE_STATIC,ALLOC_SPACE_CACHE};
9extern int alloc_space;
10void *jmalloc(int32_t size, char const *what_for);
11void *jrealloc(void *ptr, int32_t size, char const *what_for);
12void jfree(void *ptr);
13void mem_report(char const *filename);
14void jmalloc_init(int32_t min_size);
15void jmalloc_uninit();
16int32_t j_allocated();
17int32_t j_available();
18extern void free_up_memory();
19#else
20#define jmalloc(x,y) malloc(x)
21#define jrealloc(x,y,z) realloc(x,y)
22#define jfree(x) free(x)
23#endif
24
25
26
27
28#endif
29
30
31
32
33
Note: See TracBrowser for help on using the repository browser.