From 42a320064c9f8aa7dc9516ec1c52ac47dcdd77d8 Mon Sep 17 00:00:00 2001 From: David Adam Date: Mon, 6 Mar 2017 21:39:37 +0800 Subject: [PATCH] fallback: restore wcsndup fallback for Apple platforms Problem introduced in commit 002757225a3e3. --- src/fallback.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/fallback.cpp b/src/fallback.cpp index c20563b01..b73807875 100644 --- a/src/fallback.cpp +++ b/src/fallback.cpp @@ -191,6 +191,8 @@ int wcsncasecmp(const wchar_t *a, const wchar_t *b, size_t n) { #endif #endif +#endif // __APPLE__ + #ifndef HAVE_WCSNDUP wchar_t *wcsndup(const wchar_t *in, size_t c) { wchar_t *res = (wchar_t *)malloc(sizeof(wchar_t) * (c + 1)); @@ -202,8 +204,6 @@ wchar_t *wcsndup(const wchar_t *in, size_t c) { } #endif -#endif // __APPLE__ - #ifndef HAVE_WCSLCPY /*$OpenBSD: strlcpy.c,v 1.8 2003/06/17 21:56:24 millert Exp $*/