From 6ac5a82eecb76ec35f3f484149ad668073a52620 Mon Sep 17 00:00:00 2001 From: "Federico G. Schwindt" Date: Mon, 26 Aug 2013 10:47:04 +0100 Subject: private strndup() implementation in case libc does not provide it --- src/portab/portab.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/portab/portab.h') diff --git a/src/portab/portab.h b/src/portab/portab.h index 208d3500..a968a3b9 100644 --- a/src/portab/portab.h +++ b/src/portab/portab.h @@ -157,6 +157,10 @@ extern size_t strlcpy PARAMS(( char *dst, const char *src, size_t size )); extern char * strdup PARAMS(( const char *s )); #endif +#ifndef HAVE_STRNDUP +extern char * strndup PARAMS((const char *s, size_t maxlen)); +#endif + #ifndef HAVE_STRTOK_R extern char * strtok_r PARAMS((char *str, const char *delim, char **saveptr)); #endif -- cgit 1.4.1