Last change
on this file since 28 was
17,
checked in by Sam Hocevar, 18 years ago
|
- absolute shitloads of 64 bit fixes.
|
File size:
572 bytes
|
Line | |
---|
1 | #ifndef __jmalloc_hpp_ |
---|
2 | #define __jmalloc_hpp_ |
---|
3 | |
---|
4 | |
---|
5 | #include <stdlib.h> |
---|
6 | |
---|
7 | #ifdef MANAGE_MEM |
---|
8 | enum {ALLOC_SPACE_STATIC,ALLOC_SPACE_CACHE}; |
---|
9 | extern int alloc_space; |
---|
10 | void *jmalloc(int32_t size, char *what_for); |
---|
11 | void *jrealloc(void *ptr, int32_t size, char *what_for); |
---|
12 | void jfree(void *ptr); |
---|
13 | void mem_report(char *filename); |
---|
14 | void jmalloc_init(int32_t min_size); |
---|
15 | void jmalloc_uninit(); |
---|
16 | int32_t j_allocated(); |
---|
17 | int32_t j_available(); |
---|
18 | extern 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.