[WLDAP32] Sync with Wine Staging 1.9.4. CORE-10912
[reactos.git] / reactos / dll / win32 / wldap32 / wldap32.h
index 00a85a3..5a58fe8 100644 (file)
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
+#pragma once
+
+#include <wine/unicode.h>
+
 extern HINSTANCE hwldap32 DECLSPEC_HIDDEN;
 
 ULONG map_error( int ) DECLSPEC_HIDDEN;
@@ -37,6 +41,17 @@ static inline char *strdupU( const char *src )
     return dst;
 }
 
+static inline WCHAR *strdupW( const WCHAR *src )
+{
+    WCHAR *dst;
+
+    if (!src) return NULL;
+    dst = HeapAlloc( GetProcessHeap(), 0, (strlenW( src ) + 1) * sizeof(WCHAR) );
+    if (dst)
+        strcpyW( dst, src );
+    return dst;
+}
+
 static inline LPWSTR strAtoW( LPCSTR str )
 {
     LPWSTR ret = NULL;