summaryrefslogtreecommitdiff
path: root/lib/skin_parser/skin_buffer.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/skin_parser/skin_buffer.h')
-rw-r--r--lib/skin_parser/skin_buffer.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/skin_parser/skin_buffer.h b/lib/skin_parser/skin_buffer.h
index 1698b8afb2..b2ed34e09f 100644
--- a/lib/skin_parser/skin_buffer.h
+++ b/lib/skin_parser/skin_buffer.h
@@ -27,7 +27,18 @@
27#define _SKIN_BUFFFER_H_ 27#define _SKIN_BUFFFER_H_
28void skin_buffer_init(char* buffer, size_t size); 28void skin_buffer_init(char* buffer, size_t size);
29/* Allocate size bytes from the buffer */ 29/* Allocate size bytes from the buffer */
30
31/* #define DEBUG_SKIN_ALLOCATIONS */
32
33#ifdef DEBUG_SKIN_ALLOCATIONS
34#define FOO(X) #X
35#define STRNG(X) FOO(X)
36#define skin_buffer_alloc(s) skin_buffer_alloc_ex(s, __FILE__ ":" STRNG(__LINE__))
37void* skin_buffer_alloc_ex(size_t size, char* str);
38#else
30void* skin_buffer_alloc(size_t size); 39void* skin_buffer_alloc(size_t size);
40#endif
41
31 42
32/* get the number of bytes currently being used */ 43/* get the number of bytes currently being used */
33size_t skin_buffer_usage(void); 44size_t skin_buffer_usage(void);