1: # include   <sccs.h>
   2: 
   3: SCCSID(@(#)xfree.c	8.1	12/31/84)
   4: 
   5: /*
   6: **  XFREE -- free memory only if dynamically allocated.
   7: **
   8: **	This acts just like "free", except that it does nothing
   9: **	if the area handed to it hasn't been dynamically allocated.
  10: **
  11: **	Parameters:
  12: **		p -- a pointer to the area to free.
  13: **
  14: **	Returns:
  15: **		none.
  16: **
  17: **	Side Effects:
  18: **		Free memory queue is changed.
  19: **
  20: **	WARNING:
  21: **		This routine depends on the implementation of malloc
  22: **		in C; it may have to be changed on other systems.
  23: */
  24: 
  25: xfree(p)
  26: char    *p;
  27: {
  28:     extern char end[];
  29: 
  30:     if (p >= end && p < (char *) &p)
  31:         free(p);
  32: }

Defined functions

xfree defined in line 3; never used
Last modified: 1986-04-17
Generated: 2016-12-26
Generated by src2html V0.67
page hit count: 698
Valid CSS Valid XHTML 1.0 Strict