(ANSI Standard)
#include <stdlib.h> ptr = malloc( size );
"malloc" returns a pointer to space starting at an alignment boundary suitable for storing an object of any type. This space is at least "size" bytes long.
The UNIX version of "malloc" returns a NULL pointer if the desired amount of memory cannot be obtained. This doesn't happen with SS mode C -- if a program asks for more memory and is denied, the program is automatically aborted by TSS. Thus, in SS mode C, "malloc" never returns the NULL pointer.
Copyright © 1996, Thinkage Ltd.