summaryrefslogtreecommitdiff
path: root/src/stdlib/malloc.c
blob: 01924ee455557a3d8fff9676f902da3eae294ad7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#if 0

#include <stdlib.h>

/** allocate memory **/
void * malloc(size_t size)
{
	if (size == 0) {
		return NULL;
	}

	return realloc(NULL, size);
}

/***
allocates ARGUMENT(size) bytes of memory.
***/

/*
UNSPECIFIED(The order and contiguity of space allocated by success calls)
IMPLEMENTATION(What is returned if ARGUMENT(size) is 0)
RETURN_FAILURE(CONSTANT(NULL))
RETURN_SUCCESS(a pointer to the allocated space)
STDC(1)
*/


#endif