=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/make/buf.c,v retrieving revision 1.15 retrieving revision 1.16 diff -c -r1.15 -r1.16 *** src/usr.bin/make/buf.c 2001/05/03 13:41:01 1.15 --- src/usr.bin/make/buf.c 2001/05/23 12:34:40 1.16 *************** *** 1,5 **** /* $OpenPackages$ */ ! /* $OpenBSD: buf.c,v 1.15 2001/05/03 13:41:01 espie Exp $ */ /* $NetBSD: buf.c,v 1.9 1996/12/31 17:53:21 christos Exp $ */ /* --- 1,5 ---- /* $OpenPackages$ */ ! /* $OpenBSD: buf.c,v 1.16 2001/05/23 12:34:40 espie Exp $ */ /* $NetBSD: buf.c,v 1.9 1996/12/31 17:53:21 christos Exp $ */ /* *************** *** 71,91 **** * Functions for automatically-expanded buffers. */ ! #include "sprite.h" ! #include "make.h" ! #include "buf.h" ! #include "stats.h" - #ifndef lint - #if 0 - static char sccsid[] = "@(#)buf.c 8.1 (Berkeley) 6/6/93"; - #else - UNUSED - static char rcsid[] = "$OpenBSD: buf.c,v 1.15 2001/05/03 13:41:01 espie Exp $"; - #endif - #endif /* not lint */ - - #ifdef STATS_BUF #define DO_STAT_BUF(bp, nb) \ STAT_BUFS_EXPANSION++; \ --- 71,84 ---- * Functions for automatically-expanded buffers. */ ! #include ! #include ! #include "config.h" ! #include "defines.h" ! #include "buf.h" ! #include "stats.h" ! #include "memory.h" #ifdef STATS_BUF #define DO_STAT_BUF(bp, nb) \ STAT_BUFS_EXPANSION++; \ *************** *** 95,102 **** #define DO_STAT_BUF(a, b) #endif ! /* BufExpand -- ! * Expand the given buffer to hold the given number of additional * chars. Makes sure there's room for an extra '\0' char at * the end of the buffer to terminate the string. */ #define BufExpand(bp,nb) \ --- 88,95 ---- #define DO_STAT_BUF(a, b) #endif ! /* BufExpand(bp, nb) ! * Expand buffer bp to hold upto nb additional * chars. Makes sure there's room for an extra '\0' char at * the end of the buffer to terminate the string. */ #define BufExpand(bp,nb) \ *************** *** 117,123 **** #define BUF_DEF_SIZE 256 /* Default buffer size */ #define BUF_MARGIN 256 /* Make sure we are comfortable */ ! /* Buf_AddChar hard case: buffer must be expanded to accommodate * one more char. */ void BufOverflow(bp) --- 110,116 ---- #define BUF_DEF_SIZE 256 /* Default buffer size */ #define BUF_MARGIN 256 /* Make sure we are comfortable */ ! /* the hard case for Buf_AddChar: buffer must be expanded to accommodate * one more char. */ void BufOverflow(bp) *************** *** 144,151 **** void Buf_Init(bp, size) ! Buffer bp; /* New Buffer to initialize */ ! size_t size; /* Initial size for the buffer */ { #ifdef STATS_BUF STAT_TOTAL_BUFS++; --- 137,144 ---- void Buf_Init(bp, size) ! Buffer bp; ! size_t size; { #ifdef STATS_BUF STAT_TOTAL_BUFS++;