Alistair Leslie-Hughes leslie_alistair@hotmail.com writes:
@@ -101,6 +102,21 @@ static inline WCHAR *heap_strdupAtoW(const char *str) return ret; }
+static char *WtoA(LPCWSTR wstr) +{
- int length;
- char *result;
- length = WideCharToMultiByte(CP_UTF8, 0, wstr, -1, NULL, 0, NULL, NULL);
- result = HeapAlloc(GetProcessHeap(), 0, length);
- if (result)
WideCharToMultiByte(CP_UTF8, 0, wstr, -1, result, length, NULL, NULL);
- return result;
UTF-8 makes no sense here, and you shouldn't need that function in the first place.