From 9ca484d4c6f7f429552655ca7b9e5226698cc30b Mon Sep 17 00:00:00 2001 From: Fedor Indutny Date: Thu, 19 Dec 2013 14:58:26 +0400 Subject: [PATCH] test: fix build on osx --- test.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/test.c b/test.c index 18e081e..58de2ab 100644 --- a/test.c +++ b/test.c @@ -1525,12 +1525,15 @@ strlncat(char *dst, size_t len, const char *src, size_t n) return slen + dlen; } +#ifndef strlcat size_t strlcat(char *dst, const char *src, size_t len) { return strlncat(dst, len, src, (size_t) -1); } +#endif /* !strlcat */ +#ifndef strlncpy size_t strlncpy(char *dst, size_t len, const char *src, size_t n) { @@ -1548,12 +1551,15 @@ strlncpy(char *dst, size_t len, const char *src, size_t n) assert(len > slen); return slen; } +#endif /* !strlncpy */ +#ifndef strlcpy size_t strlcpy(char *dst, const char *src, size_t len) { return strlncpy(dst, len, src, (size_t) -1); } +#endif /* !strlcpy */ int request_url_cb (http_parser *p, const char *buf, size_t len)