(svn r14154) -Fix (r14153): strndup is a GNU extension, so it doesn't exist on all platforms

This commit is contained in:
glx
2008-08-24 17:02:21 +00:00
parent ae32d158cb
commit 2ddb86eea5
3 changed files with 22 additions and 1 deletions

View File

@@ -156,4 +156,9 @@ static inline bool IsWhitespace(WChar c)
;
}
#endif /* STRING_FUNC_H */
#ifndef _GNU_SOURCE
/* strndup is a GNU extension */
char *strndup(const char *s, size_t len);
#endif /* WIN32 || SUNOS */
#endif /* !_GNU_SOURCE */