IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 11066


Ignore:
Timestamp:
Jan 12, 2007, 8:26:41 AM (19 years ago)
Author:
eugene
Message:

added FREE (accepts a NULL ptr)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Ohana/src/libohana/include/ohana_allocate.h

    r4300 r11066  
    2323  if ((N) >= (S)) { S += D; \
    2424  X = (T *) ohana_realloc(__FILE__, __LINE__, X, (S), sizeof(T)); }
     25# define FREE(X) if (X != NULL) { ohana_free (__FILE__, __LINE__, X); }
    2526# define free(X) ohana_free(__FILE__, __LINE__, X)
    2627
     
    4950      fprintf(stderr,"failed realloc increment at %d in %s\n", __LINE__, __FILE__);\
    5051      exit (10); } }
     52# define FREE(X) if (X != NULL) { free (X); }
    5153# endif /* ALLOCATE */
    5254
Note: See TracChangeset for help on using the changeset viewer.