home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / unix / volume3 / pathalias2 / part1 / config.h < prev    next >
Encoding:
C/C++ Source or Header  |  1986-11-30  |  2.0 KB  |  76 lines

  1. /* pathalias -- by steve bellovin, as told to peter honeyman */
  2.  
  3. #define STRCHR        /* have strchr, not index -- probably system v */
  4. #define UNAME        /* have uname() -- probably system v or 8th ed. */
  5. #define MEMSET        /* have memset() -- probably system v or 8th ed. */
  6.  
  7. /* #define GETHOSTNAME    /* have gethostname() -- probably 4.2bsd */
  8. /* #define BZERO    /* have bzero() -- probably 4.2bsd */
  9.  
  10. /* default place for dbm output of makedb (or use -o file at run-time) */
  11. #define    ALIASDB    "/usr/local/lib/palias"
  12.  
  13.  
  14.  
  15. /**************************************************************************
  16.  *                                      *
  17.  * +--------------------------------------------------------------------+ *
  18.  * |                                    | *
  19.  * |            END OF CONFIGURATION SECTION            | *
  20.  * |                                    | *
  21.  * |                EDIT NO MORE                | *
  22.  * |                                    | *
  23.  * +--------------------------------------------------------------------+ *
  24.  *                                      *
  25.  **************************************************************************/
  26.  
  27. #ifdef MAIN
  28. #ifndef lint
  29. static char    *c_sccsid = "@(#)config.h    8.1 (down!honey) 86/01/19";
  30. #endif /*lint*/
  31. #endif /*MAIN*/
  32.  
  33. /*
  34.  * malloc/free fine tuned for pathalias.
  35.  *
  36.  * MYMALLOC should work everwhere, so it's not a configuration
  37.  * option (anymore).  nonetheless, if you're getting strange
  38.  * core dumps (or panics!), comment out the following manifest,
  39.  * and use the inferior C library malloc/free.
  40.  *
  41.  * report problems to princeton!honey.
  42.  */
  43. #define MYMALLOC    /**/
  44.  
  45. #ifdef MYMALLOC
  46. #define malloc mymalloc
  47. #define calloc(n, s) malloc ((n)*(s))
  48. #define free(s)
  49. #define cfree(s)
  50. extern char *memget();
  51. #endif
  52.  
  53. #ifdef STRCHR
  54. #define index strchr
  55. #define rindex strrchr
  56. #else
  57. #define strchr index
  58. #define strrchr rindex
  59. #endif
  60.  
  61. #ifdef BZERO
  62. #define strclear(s, n)    ((void) bzero((s), (n)))
  63. #else /*!BZERO*/
  64.  
  65. #ifdef MEMSET
  66. extern char    *memset();
  67. #define strclear(s, n)    ((void) memset((s), 0, (n)))
  68. #else /*!MEMSET*/
  69. extern void    strclear();
  70. #endif /*MEMSET*/
  71.  
  72. #endif /*BZERO*/
  73.  
  74. extern char    *malloc();
  75. extern char    *strcpy(), *index(), *rindex();
  76.