summaryrefslogtreecommitdiff
path: root/compiler.h
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2009-08-10 15:56:52 -0700
committerH. Peter Anvin <hpa@zytor.com>2009-08-10 15:59:34 -0700
commiteaa68f1c85126fa48601f3a40e9c930b01f8660e (patch)
tree4bdea44a5e06cc5b1f5de2fc59391b8972a7a2d8 /compiler.h
parent767750b666f0e66b25fa9d1c7b905a935c637786 (diff)
downloadnasm-eaa68f1c85126fa48601f3a40e9c930b01f8660e.tar.gz
nasm-eaa68f1c85126fa48601f3a40e9c930b01f8660e.tar.bz2
nasm-eaa68f1c85126fa48601f3a40e9c930b01f8660e.zip
Add strlcpy() function
Add strlcpy() function and implementation, and use configure to detect if strlcpy() is natively available on the system. Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'compiler.h')
-rw-r--r--compiler.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/compiler.h b/compiler.h
index d96ebcb..5805f5a 100644
--- a/compiler.h
+++ b/compiler.h
@@ -100,6 +100,10 @@ int vsnprintf(char *, size_t, const char *, va_list);
# endif
#endif
+#if !defined(HAVE_STRLCPY) || !HAVE_DECL_STRLCPY
+size_t strlcpy(char *, const char *, size_t);
+#endif
+
#ifndef __cplusplus /* C++ has false, true, bool as keywords */
# if defined(HAVE_STDBOOL_H) && defined(HAVE_WORKING_BOOL)
# include <stdbool.h>