Release 0.6
[wine] / include / user.h
1 /*
2  * USER definitions
3  *
4  * Copyright 1993 Alexandre Julliard
5  */
6
7 #ifndef USER_H
8 #define USER_H
9
10 #include "segmem.h"
11 #include "heap.h"
12
13   /* USER local heap */
14
15 extern MDESC *USER_Heap;
16
17 #define USER_HEAP_ALLOC(f,size) ((int)HEAP_Alloc(&USER_Heap,f,size) & 0xffff)
18 #define USER_HEAP_REALLOC(handle,size,f) ((int)HEAP_ReAlloc(&USER_Heap, \
19                                        USER_HEAP_ADDR(handle),size,f) & 0xffff)
20 #define USER_HEAP_ADDR(handle) ((void *)(handle|((int)USER_Heap & 0xffff0000)))
21 #define USER_HEAP_FREE(handle) (HEAP_Free(&USER_Heap,USER_HEAP_ADDR(handle)))
22
23 #endif  /* USER_H */