Add a library "host_wcsfuncs" with implementations for UTF-16 string functions needed...
[reactos.git] / reactos / tools / mkhive / rtl.c
index 1ccb8ac..eec2fc3 100644 (file)
 #include "mkhive.h"
 #include <bitmap.c>
 
-SIZE_T xwcslen( PCWSTR String ) {
-       SIZE_T i;
-
-       for( i = 0; String[i]; i++ );
-
-       return i;
-}
-
-PWSTR xwcschr( PWSTR String, WCHAR Char )
-{
-       SIZE_T i;
-
-       for( i = 0; String[i] && String[i] != Char; i++ );
-
-       if( String[i] ) return &String[i];
-       else return NULL;
-}
-
-int xwcsncmp(PCWSTR s1, PCWSTR s2, size_t n)
-{
-    while(n--)
-    {
-        if(*s1 != *s2)
-            return 1;
-
-        if(*s1 == 0)
-            return 0;
-
-        s1++;
-        s2++;
-    }
-
-    return 0;
-}
-
 /*
  * @implemented
  *
@@ -88,7 +53,7 @@ RtlInitUnicodeString(
 
        if(SourceString)
        {
-               DestSize = xwcslen(SourceString) * sizeof(WCHAR);
+               DestSize = utf16_wcslen(SourceString) * sizeof(WCHAR);
                DestinationString->Length = (USHORT)DestSize;
                DestinationString->MaximumLength = (USHORT)DestSize + sizeof(WCHAR);
        }