【发布时间】:2012-03-11 15:27:51
【问题描述】:
现在我有了这段代码,但它总是设置为 null
UNICODE_STRING str;
char *cmp = "Hello";
RtlInitUnicodeString (&str, L"Hello world!");
if( ( strstr((char * )str.Buffer, cmp) ) != NULL)
{
// cmp founded in str.
}
else
{
// cmp not founded in str. Always here, but why??
}
你能解释一下为什么我的 strstr 总是 null 吗?
【问题讨论】:
标签: c string winapi unicode-string