mirror of
https://github.com/ChronosX88/nesca.git
synced 2024-11-23 18:52:19 +00:00
--
This commit is contained in:
parent
ba8d98ee71
commit
51ef7cd65d
15
finder.cpp
15
finder.cpp
@ -408,19 +408,22 @@ int ContentFilter(char *buff, int port, char *ip, char *cp)
|
|||||||
if(buff != NULL)
|
if(buff != NULL)
|
||||||
{
|
{
|
||||||
int res = 0;
|
int res = 0;
|
||||||
std::string tempString = toLowerStr(buff);
|
std::string tempString = "";
|
||||||
int sz = tempString.size();
|
|
||||||
char *lBuff = new char[sz + 1];
|
|
||||||
ZeroMemory(lBuff, sz + 1);
|
|
||||||
|
|
||||||
if(strstr(cp, "1251") != NULL)
|
if(strstr(cp, "1251") != NULL)
|
||||||
{
|
{
|
||||||
strcpy(lBuff, toLowerStr(buff).c_str());
|
tempString = toLowerStr(buff);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
strcpy(lBuff, toLowerStr(xcode(buff, CP_UTF8, CP_ACP).c_str()).c_str());
|
tempString = toLowerStr(xcode(buff, CP_UTF8, CP_ACP).c_str());
|
||||||
};
|
};
|
||||||
|
|
||||||
|
int sz = tempString.size();
|
||||||
|
char *lBuff = new char[sz + 1];
|
||||||
|
ZeroMemory(lBuff, sz + 1);
|
||||||
|
strcpy(lBuff, tempString.c_str());
|
||||||
|
|
||||||
memset(lBuff + sz, '\0', 1);
|
memset(lBuff + sz, '\0', 1);
|
||||||
if(sz <= 500)
|
if(sz <= 500)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user