mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-06-02 22:21:15 -03:00
fallback: restore wcsndup fallback for Apple platforms
Problem introduced in commit 002757225a.
This commit is contained in:
@@ -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 $*/
|
||||
|
||||
|
||||
Reference in New Issue
Block a user