source: trunk/src/emx/include/malloc.h@ 1092

Last change on this file since 1092 was 1087, checked in by bird, 22 years ago

USE_EMX and _POSIX_[C_]SOURCE problems with new features.h.

  • Property cvs2svn:cvs-rev set to 1.5
  • Property svn:eol-style set to native
  • Property svn:executable set to *
File size: 1.2 KB
Line 
1/* malloc.h (emx+gcc) */
2
3#ifndef _MALLOC_H
4#define _MALLOC_H
5
6#if defined (__cplusplus)
7extern "C" {
8#endif
9
10#if !defined (_SIZE_T) && !defined (_SIZE_T_DECLARED)
11#define _SIZE_T
12#define _SIZE_T_DECLARED
13typedef unsigned long size_t;
14#endif
15
16#if !defined (NULL)
17#if defined (__cplusplus)
18#define NULL 0
19#else
20#define NULL ((void *)0)
21#endif
22#endif
23
24
25void *calloc (size_t, size_t);
26void free (void *);
27void *malloc (size_t);
28void *realloc (void *, size_t);
29
30
31#if (!defined (__STRICT_ANSI__) && !defined (_POSIX_SOURCE)) || defined (_WITH_UNDERSCORE) || defined(__USE_EMX)
32
33#if !defined (_HEAPOK)
34#define _HEAPOK 0
35#define _HEAPEMPTY 1
36#define _HEAPBADBEGIN 2
37#define _HEAPBADNODE 3
38#define _HEAPBADEND 4
39#define _HEAPBADROVER 5
40#endif
41
42void *_tcalloc (size_t, size_t);
43void _tfree (void *);
44int _theapmin (void);
45void *_tmalloc (size_t);
46void *_trealloc (void *, size_t);
47
48void *_expand (void *, size_t);
49int _heapchk (void);
50int _heapmin (void);
51int _heapset (unsigned);
52int _heap_walk (int (*)(__const__ void *, size_t, int, int,
53 __const__ char *, size_t));
54size_t _msize (__const__ void *);
55
56#endif
57
58
59#if defined (__cplusplus)
60}
61#endif
62
63#endif /* not _MALLOC_H */
Note: See TracBrowser for help on using the repository browser.