3 LICENSE: GPL v2 or any later version
4 FILE: lib/host/wcsfuncs/wcsfuncs.c
5 PURPOSE: Reimplemented wide-character string functions for host tools (to be independent of the host wchar_t size)
6 COPYRIGHT: Copyright 2008 Colin Finck <mail@colinfinck.de>
9 #include <host/typedefs.h>
11 /* Function implementations */
12 SIZE_T
utf16_wcslen(PCWSTR str
)
16 for(i
= 0; str
[i
]; i
++);
21 PWSTR
utf16_wcschr(PWSTR str
, WCHAR c
)
25 for(i
= 0; str
[i
] && str
[i
] != c
; i
++);
33 INT
utf16_wcsncmp(PCWSTR string1
, PCWSTR string2
, size_t count
)
37 if(*string1
!= *string2
)