Main Page   Data Structures   File List   Data Fields   Globals   Related Pages  

xmalloc.h File Reference

contains customized realloc(), malloc() and free() functions. More...

#include "common.h"
#include <sys/types.h>

Include dependency graph for xmalloc.h:

Include dependency graph

This graph shows which files directly or indirectly include this file:

Included by dependency graph

Go to the source code of this file.

Functions

void * pd_realloc (void *ptr, size_t size)
 reallocs mem like realloc(). More...

void * pd_malloc (size_t size)
 Allocates memory like malloc(), but exits the programm, if it fails! More...

void pd_free (void *ptr)
 frees memory like free(), but not, if ptr == NULL. More...


Detailed Description

contains customized realloc(), malloc() and free() functions.

Definition in file xmalloc.h.


Function Documentation

void pd_free void *    ptr
 

frees memory like free(), but not, if ptr == NULL.

Parameters:
ptr  the pointer to be freed
if ptr == NULL, nothing is changed

Referenced by buildBasicHeader(), buildEntityHeader(), chTerminate(), getAbsPath(), getLine(), htAddData(), htMthdParse(), htRecvLine(), htSend(), htTerminate(), logTerminate(), logfilesInit(), main(), mimeInit(), readConfigFile(), resolvURI(), rhfSend(), rhfTerminate(), setEntry(), and terminateConftable().

void* pd_malloc size_t    size
 

Allocates memory like malloc(), but exits the programm, if it fails!

Parameters:
size  the amount of memory to be allocated
Returns:
a pointer to allocated memory of size size

Referenced by appendHdrField(), buildBasicHeader(), buildEntityHeader(), chInit(), getAbsPath(), htAddData(), htInit(), htMthdParse(), htRecvLine(), logInitStream_int(), logfilesInit(), main(), mimeInit(), readConfigFile(), resolvURI(), rhfInit(), and setEntry().

void* pd_realloc void *    ptr,
size_t    size
 

reallocs mem like realloc().

Parameters:
ptr  the pointer whose allocated memory should be changed in size
size  the new size of allocated memory of ptr
Returns:
a pointer to the new allocated memory. if the realloc() failed, NULL is returned

Referenced by copyRequestLine(), and getLine().


Generated on Fri Jan 25 22:41:03 2002 for PDepp Webserver by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001