home *** CD-ROM | disk | FTP | other *** search
/ Unix System Administration Handbook 1997 October / usah_oct97.iso / news / cnews.tar / libcnews / nemalloc.c < prev    next >
C/C++ Source or Header  |  1991-11-06  |  240b  |  14 lines

  1. #include <stdio.h>
  2. #include <stdlib.h>
  3.  
  4. char *
  5. nemalloc(size)            /* news emalloc - calls errunlock on error */
  6. unsigned size;
  7. {
  8.     register char *result = malloc(size);
  9.  
  10.     if (result == NULL)
  11.         errunlock("out of memory", "");
  12.     return result;
  13. }
  14.