#include "emalloc.h"
#include "danerror.h"
#include <stdlib.h>
Go to the source code of this file.
Functions |
| void * | Emalloc (size_t Size) |
| void * | Erealloc (void *ptr, size_t size) |
| void | Efree (void *ptr) |
Function Documentation
| void* Emalloc |
( |
size_t |
Size | ) |
|
Include Files and Type Defines —————————————————————————- ---------------------------------------------------------------------------- Public Code —————————————————————————-
Definition at line 35 of file emalloc.cpp.
{
void *Buffer;
if (Size <= 0)
Buffer = (void *) malloc (Size);
}
else
return (Buffer);
}
| void* Erealloc |
( |
void * |
ptr, |
|
|
size_t |
size |
|
) |
| |
Definition at line 70 of file emalloc.cpp.
{
void *Buffer;
if (size < 0 || (size == 0 && ptr ==
NULL))
Buffer = (void *) realloc (ptr, size);
if (Buffer ==
NULL && size != 0)
return (Buffer);
}