if else 的超级怪异问题
if(stricmp(ext,".doc")==0)
return 1;
else if(stricmp(ext,".xls")==0)
return 2;
else if(stricmp(ext,".dwg")==0)
return 3;
else if(stricmp(ext,".psd")==0)
return 4;
else if(stricmp(ext,".pdf")==0)
return 5;
else if(stricmp(ext,".txt")==0)
{
// m_listCtrl.InsertItem(0,"txt");
return 6;
}
else
return 0;
如果上面的被注释的语句没有注释掉,则返回值正常
否则当ext=".txt"时返回0……