请问应该怎样把这个w_char取出来??
wchar_t* unicoudToMuil(const char* cha)
{
wchar_t* tt = NULL;
int len = MultiByteToWideChar(CP_ACP,0,cha,-1,NULL,0);
wchar_t* gg = new wchar_t[len];
MultiByteToWideChar(CP_ACP,0,cha,-1,gg,len);
tt = gg;
delete[] gg;
return tt;
}
在我的程序里
...
wchar_t* tt = null;//这里我不想每次都new出来tt
tt = unicoudToMuil("测试");
//tt这里是个乱值,请问应该如何解决
...