diff options
| author | tv <tv@NetBSD.org> | 2002-01-21 21:33:42 +0000 |
|---|---|---|
| committer | tv <tv@NetBSD.org> | 2002-01-21 21:33:42 +0000 |
| commit | c08a2cb7c28608c4d750d08dbccb76ac0e313cb6 (patch) | |
| tree | 085e938afd6330610d785ee242dd5c8f0b49b2c6 /lib/libc/string | |
| parent | 9c06c04bee36325f1c7c0d2ce47c5ed6524c173f (diff) | |
Add hooks for reachover builds from src/tools/compat.
Diffstat (limited to 'lib/libc/string')
| -rw-r--r-- | lib/libc/string/strlcat.c | 10 | ||||
| -rw-r--r-- | lib/libc/string/strlcpy.c | 10 |
2 files changed, 16 insertions, 4 deletions
diff --git a/lib/libc/string/strlcat.c b/lib/libc/string/strlcat.c index d766940fc71..a9dbcbce3f9 100644 --- a/lib/libc/string/strlcat.c +++ b/lib/libc/string/strlcat.c @@ -1,4 +1,4 @@ -/* $NetBSD: strlcat.c,v 1.9 2001/11/16 04:17:25 itojun Exp $ */ +/* $NetBSD: strlcat.c,v 1.10 2002/01/21 21:33:42 tv Exp $ */ /* $OpenBSD: strlcat.c,v 1.4 2001/01/12 22:55:23 millert Exp $ */ /* @@ -28,15 +28,20 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#if HAVE_CONFIG_H +#include "config.h" +#else #include <sys/cdefs.h> #if defined(LIBC_SCCS) && !defined(lint) -__RCSID("$NetBSD: strlcat.c,v 1.9 2001/11/16 04:17:25 itojun Exp $"); +__RCSID("$NetBSD: strlcat.c,v 1.10 2002/01/21 21:33:42 tv Exp $"); #endif /* LIBC_SCCS and not lint */ #include <sys/types.h> #include <assert.h> #include <string.h> +#endif +#if !HAVE_STRLCAT /* * Appends src to string dst of size siz (unlike strncat, siz is the * full size of dst, not space left). At most siz-1 characters @@ -77,3 +82,4 @@ strlcat(dst, src, siz) return(dlen + (s - src)); /* count does not include NUL */ } +#endif diff --git a/lib/libc/string/strlcpy.c b/lib/libc/string/strlcpy.c index 5c11c3ac229..e2bdf621b51 100644 --- a/lib/libc/string/strlcpy.c +++ b/lib/libc/string/strlcpy.c @@ -1,4 +1,4 @@ -/* $NetBSD: strlcpy.c,v 1.7 2001/01/13 04:19:54 itojun Exp $ */ +/* $NetBSD: strlcpy.c,v 1.8 2002/01/21 21:33:42 tv Exp $ */ /* $OpenBSD: strlcpy.c,v 1.4 1999/05/01 18:56:41 millert Exp $ */ /* @@ -28,15 +28,20 @@ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#if HAVE_CONFIG_H +#include "config.h" +#else #include <sys/cdefs.h> #if defined(LIBC_SCCS) && !defined(lint) -__RCSID("$NetBSD: strlcpy.c,v 1.7 2001/01/13 04:19:54 itojun Exp $"); +__RCSID("$NetBSD: strlcpy.c,v 1.8 2002/01/21 21:33:42 tv Exp $"); #endif /* LIBC_SCCS and not lint */ #include <sys/types.h> #include <assert.h> #include <string.h> +#endif +#if !HAVE_STRLCPY /* * Copy src to string dst of size siz. At most siz-1 characters * will be copied. Always NUL terminates (unless siz == 0). @@ -73,3 +78,4 @@ strlcpy(dst, src, siz) return(s - src - 1); /* count does not include NUL */ } +#endif |
