Import list restore fix

This commit is contained in:
cora32 2014-11-07 20:22:39 +03:00
parent 2600cb48e5
commit e60cb3a02e
3 changed files with 34 additions and 18 deletions

View File

@ -28,10 +28,13 @@ void BConInc()
}; };
void BConDec() void BConDec()
{ {
if(BrutingThrds > 0)
{
__asm __asm
{ {
lock dec BrutingThrds; lock dec BrutingThrds;
}; };
}
#pragma region QTGUI_Area #pragma region QTGUI_Area
stt->doEmitionChangeBA(QString::number(BrutingThrds)); stt->doEmitionChangeBA(QString::number(BrutingThrds));
#pragma endregion #pragma endregion

View File

@ -295,7 +295,7 @@ int _mainFinderFirst(char *buffcpy, int f, int port, char *ip)
if(strstr(buffcpy, "camera web server") != NULL || strstr(buffcpy, "webcamxp 5") != NULL if(strstr(buffcpy, "camera web server") != NULL || strstr(buffcpy, "webcamxp 5") != NULL
|| strstr(buffcpy, "ip box camera") != NULL || strstr(buffcpy, "snaff") != NULL || strstr(buffcpy, "ip box camera") != NULL || strstr(buffcpy, "snaff") != NULL
|| strstr(buffcpy, "hfs /") != NULL || strstr(buffcpy, "httpfileserver") != NULL || strstr(buffcpy, "hfs /") != NULL || strstr(buffcpy, "httpfileserver") != NULL
|| strstr(buffcpy, "network camera server") != NULL || strstr(buffcpy, "network camera") != NULL
|| strstr(buffcpy, "$lock extended") != NULL || strstr(buffcpy, "ip camera") != NULL || strstr(buffcpy, "$lock extended") != NULL || strstr(buffcpy, "ip camera") != NULL
|| strstr(buffcpy, "/viewer/video.jpg") != NULL || strstr(buffcpy, "smart ip device") != NULL || strstr(buffcpy, "/viewer/video.jpg") != NULL || strstr(buffcpy, "smart ip device") != NULL
|| strstr(buffcpy, "sanpshot_icon") != NULL || strstr(buffcpy, "snapshot_icon") != NULL || strstr(buffcpy, "sanpshot_icon") != NULL || strstr(buffcpy, "snapshot_icon") != NULL
@ -373,7 +373,7 @@ int _mainFinderSecond(char *buffcpy, int port, char *ip)
if(strstr(buffcpy, "camera web server") != NULL || strstr(buffcpy, "webcamxp 5") != NULL if(strstr(buffcpy, "camera web server") != NULL || strstr(buffcpy, "webcamxp 5") != NULL
|| strstr(buffcpy, "ip box camera") != NULL || strstr(buffcpy, "snaff") != NULL || strstr(buffcpy, "ip box camera") != NULL || strstr(buffcpy, "snaff") != NULL
|| strstr(buffcpy, "hfs /") != NULL || strstr(buffcpy, "httpfileserver") != NULL || strstr(buffcpy, "hfs /") != NULL || strstr(buffcpy, "httpfileserver") != NULL
|| strstr(buffcpy, "network camera server") != NULL || strstr(buffcpy, "network camera") != NULL
|| strstr(buffcpy, "$lock extended") != NULL || strstr(buffcpy, "ip camera") != NULL || strstr(buffcpy, "$lock extended") != NULL || strstr(buffcpy, "ip camera") != NULL
|| strstr(buffcpy, "/viewer/video.jpg") != NULL || strstr(buffcpy, "smart ip device") != NULL || strstr(buffcpy, "/viewer/video.jpg") != NULL || strstr(buffcpy, "smart ip device") != NULL
|| strstr(buffcpy, "sanpshot_icon") != NULL || strstr(buffcpy, "snapshot_icon") != NULL || strstr(buffcpy, "sanpshot_icon") != NULL || strstr(buffcpy, "snapshot_icon") != NULL
@ -2346,28 +2346,38 @@ void _getLinkFromJSLocation(char *dataBuff, char *str, char *tag, char *ip, int
char *ptrQuote1 = _findFirst(ptr2, "\"'"); char *ptrQuote1 = _findFirst(ptr2, "\"'");
if(ptrQuote1 != NULL) if(ptrQuote1 != NULL)
{ {
char *ptrQuoteTemp = _findFirst(ptrQuote1 + 1, ";\n}");
if(ptrQuoteTemp != NULL)
{
sz = ptrQuoteTemp - ptrQuote1 + 1;
};
char *tempBuff = new char[sz + 1];
ZeroMemory(tempBuff, sizeof(tempBuff));
strncpy(tempBuff, ptrQuote1 + 1, sz);
memset(tempBuff + sz, 0, 1);
char delim[2] = {0}; char delim[2] = {0};
ZeroMemory(delim, 1); ZeroMemory(delim, 1);
delim[0] = ptrQuote1[0]; delim[0] = ptrQuote1[0];
delim[1] = '\0'; delim[1] = '\0';
char *ptrQuote2 = _findLast(ptrQuote1 + 1, delim); char *ptrQuote2 = _findLast(tempBuff + 1, delim);
if(ptrQuote2 != NULL) if(ptrQuote2 != NULL)
{ {
int lsz = ptrQuote2 - ptrQuote1 - 1; sz = ptrQuote2 - tempBuff;
char link[512] = {0}; char link[512] = {0};
if(lsz < 511) if(sz < 511)
{ {
if(ptrQuote1[1] != '/' if(tempBuff[1] != '/'
&& strstri(ptrQuote1, "http://") == NULL && strstri(tempBuff, "http://") == NULL
&& strstri(ptrQuote1, "https://") == NULL && strstri(tempBuff, "https://") == NULL
) )
{ {
strcpy(dataBuff, "/"); strcpy(dataBuff, "/");
strncat(dataBuff, ptrQuote1 + 1, lsz); strncat(dataBuff, tempBuff, sz);
} }
else strncpy(dataBuff, ptrQuote1 + 1, lsz); else strncpy(dataBuff, tempBuff, sz);
}; };
}; };
delete tempBuff;
} }
else else
{ {

View File

@ -147,10 +147,13 @@ void ConInc()
}; };
void ConDec() void ConDec()
{ {
if(cons > 0)
{
__asm __asm
{ {
lock dec cons; lock dec cons;
}; };
};
#pragma region QTGUI_Area #pragma region QTGUI_Area
stt->doEmitionThreads(QString::number(cons) + "/" + QString::number(gThreads)); stt->doEmitionThreads(QString::number(cons) + "/" + QString::number(gThreads));
#pragma endregion #pragma endregion
@ -2705,19 +2708,19 @@ void nCleanup(){
}; };
if(ipsstartfl != NULL) if(ipsstartfl != NULL)
{ {
for(int i = 0; i < MaxSSHPass; ++i) delete []ipsstartfl[i]; for(int i = 0; i < flCounter; ++i) delete []ipsstartfl[i];
delete []ipsstartfl; delete []ipsstartfl;
ipsstartfl = NULL; ipsstartfl = NULL;
}; };
if(ipsendfl != NULL) if(ipsendfl != NULL)
{ {
for(int i = 0; i < MaxSSHPass; ++i) delete []ipsendfl[i]; for(int i = 0; i < flCounter; ++i) delete []ipsendfl[i];
delete []ipsendfl; delete []ipsendfl;
ipsendfl = NULL; ipsendfl = NULL;
}; };
if(starterIP != NULL) if(starterIP != NULL)
{ {
for(int i = 0; i < MaxSSHPass; ++i) delete []starterIP[i]; for(int i = 0; i < flCounter; ++i) delete []starterIP[i];
delete []starterIP; delete []starterIP;
starterIP = NULL; starterIP = NULL;
}; };