2 ** Copyright 2011, Oliver Tappe, zooey@hirschkaefer.de. All rights reserved.
3 ** Distributed under the terms of the Haiku License.
9 #include <errno_private.h>
10 #include <wchar_private.h>
14 __wcsdup(const wchar_t* wcs
)
20 size_t bufferSize
= (wcslen(wcs
) + 1) * sizeof(wchar_t);
21 wchar_t* dest
= malloc(bufferSize
);
27 memcpy(dest
, wcs
, bufferSize
);
34 B_DEFINE_WEAK_ALIAS(__wcsdup
, wcsdup
);