Convert Unicode To UTF8
char* __stdcall UnicodeToUtf8( const WCHAR* wstr )
{
const WCHAR* w;
// Convert unicode to utf8
int len = 0;
for ( w = wstr; *w; w++ ) {
if ( *w < 0×0080 ) len++;
else if ( *w < 0×0800 ) len += 2;
el[……]