diff options
author | Brent Cook <bcook@openbsd.org> | 2014-08-02 21:43:56 -0500 |
---|---|---|
committer | Brent Cook <bcook@openbsd.org> | 2014-08-02 21:59:36 -0500 |
commit | 00b51d5c25abd0d91c7f6b25aeb3bdc8102e436b (patch) | |
tree | 436aa6d610c361c8e4b502f2ffdcf923ab3b647c /include | |
parent | c95574be9296988962cb1358c969144dc382061b (diff) | |
download | portable-00b51d5c25abd0d91c7f6b25aeb3bdc8102e436b.tar.gz portable-00b51d5c25abd0d91c7f6b25aeb3bdc8102e436b.tar.bz2 portable-00b51d5c25abd0d91c7f6b25aeb3bdc8102e436b.zip |
conditionally build strnlen if needed.
it is only used by strndup
prodded by Sortie@
Diffstat (limited to 'include')
-rw-r--r-- | include/string.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/string.h b/include/string.h index c4bf1e4..ab232a8 100644 --- a/include/string.h +++ b/include/string.h | |||
@@ -22,8 +22,10 @@ size_t strlcat(char *dst, const char *src, size_t siz); | |||
22 | 22 | ||
23 | #ifdef NO_STRNDUP | 23 | #ifdef NO_STRNDUP |
24 | char * strndup(const char *str, size_t maxlen); | 24 | char * strndup(const char *str, size_t maxlen); |
25 | #ifdef NO_STRNLEN | ||
25 | size_t strnlen(const char *str, size_t maxlen); | 26 | size_t strnlen(const char *str, size_t maxlen); |
26 | #endif | 27 | #endif |
28 | #endif | ||
27 | 29 | ||
28 | #ifdef NO_EXPLICIT_BZERO | 30 | #ifdef NO_EXPLICIT_BZERO |
29 | void explicit_bzero(void *, size_t); | 31 | void explicit_bzero(void *, size_t); |