Hello, I want to save and compare the data of a 2 packets,
and finding out if they contain the same data...
Thanks to u-coRe & Metin2Spieler97 i have something like this, and its working great!
Thanks for the help!!!
This part saves the 1rst packet to be compared.
This part check if the packets are the same :)
Now i need to build an interface!!! ANY SUGGESTIONS?
and finding out if they contain the same data...
Thanks to u-coRe & Metin2Spieler97 i have something like this, and its working great!
Thanks for the help!!!
This part saves the 1rst packet to be compared.
PHP Code:
bool paso0(const char* buf,int len){
buf2 = (char*) malloc (len);
tam_buf2=len;
for (int i = 0; i < len; ++i) /
buf2[i] = buf[i];
return true;
}
PHP Code:
bool check(const char* buf,int len,char* bufb,int lenb){
bool check=false;
int i=0;
if(len!=lenb){
}else{
while (i < len) {
if (memcmp(bufb,buf,len)==0){
check = true;
}else{
check = false;
i=len;
}
i++;
}}
return check;
}