diff options
author | harti <harti@FreeBSD.org> | 2005-02-07 07:49:16 +0000 |
---|---|---|
committer | harti <harti@FreeBSD.org> | 2005-02-07 07:49:16 +0000 |
commit | c45831f7c65accf983e86b1f1a883f20c27133e0 (patch) | |
tree | 66fb0e86c2921f8ecff474aa405874087d374906 /usr.bin/make/buf.c | |
parent | d2bbb620e902ad472a90d5c5d1fc3286b192a0a2 (diff) | |
download | FreeBSD-src-c45831f7c65accf983e86b1f1a883f20c27133e0.zip FreeBSD-src-c45831f7c65accf983e86b1f1a883f20c27133e0.tar.gz |
Invent a Buf_Append function to append a NUL-terminated string
and use it thoughout the code.
Submitted by: Max Okumoto <okumoto@ucsd.edu>
Diffstat (limited to 'usr.bin/make/buf.c')
-rw-r--r-- | usr.bin/make/buf.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/usr.bin/make/buf.c b/usr.bin/make/buf.c index 3327c7f..738f92a 100644 --- a/usr.bin/make/buf.c +++ b/usr.bin/make/buf.c @@ -194,6 +194,16 @@ Buf_ReplaceLastByte(Buffer *bp, Byte byte) } /** + * Append characters in str to Buffer object + */ +void +Buf_Append(Buffer *bp, const char str[]) +{ + + Buf_AddBytes(bp, strlen(str), str); +} + +/** * Clear the contents of the buffer. */ void |