next up previous contents index
Next: xFree Up: Storage Previous: Storage

xMalloc

Essentially the same as the Unix malloc routine. Causes an x-kernel abort if no storage is available; therefore, it has no error return value.

char *xMalloc(int size)

The x-kernel provides a macro, X_NEW, that can be used to allocate space of a certain type.

#define X_NEW(type) (type *)xMalloc(sizeof(type))



Larry Peterson
Wed Jan 10 10:40:08 MST 1996