Update of /cvsroot/javanetsim/IceScan
In directory sc8-pr-cvs6.sourceforge.net:/tmp/cvs-serv17743
Modified Files:
icediscover.h udpscan.h
Log Message:
Index: icediscover.h
===================================================================
RCS file: /cvsroot/javanetsim/IceScan/icediscover.h,v
retrieving revision 1.20
retrieving revision 1.21
diff -C2 -d -r1.20 -r1.21
*** icediscover.h 16 Dec 2006 14:44:56 -0000 1.20
--- icediscover.h 16 Dec 2006 15:24:57 -0000 1.21
***************
*** 196,200 ****
if(par->arp_discovery) if( arp_discovery(hostname, par, out) ) return true;
! // if(par->udp_ping_discovery) if( udp_discovery(hostname, par, out) ) return true;
if(par->verbose>0) *out << "Host discovery failed!" << iceoutput::endl;
--- 196,200 ----
if(par->arp_discovery) if( arp_discovery(hostname, par, out) ) return true;
! if(par->udp_ping_discovery) if( udp_discovery(hostname, par, out) ) return true;
if(par->verbose>0) *out << "Host discovery failed!" << iceoutput::endl;
Index: udpscan.h
===================================================================
RCS file: /cvsroot/javanetsim/IceScan/udpscan.h,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** udpscan.h 16 Dec 2006 14:44:56 -0000 1.8
--- udpscan.h 16 Dec 2006 15:24:57 -0000 1.9
***************
*** 70,73 ****
--- 70,74 ----
int port;
char hostname[80];
+ bool next = true;
int recvsize = UDP_SCAN_RECVSIZE;
***************
*** 82,87 ****
sicmp.setsockopt(SOL_SOCKET, SO_RCVBUF, &size, sizeof(size));
! for(repeats = 1; repeats <= UDP_SCAN_REPEATS && !(result ^ isscan); repeats++){ //exit if( isscan = false && result = true )
! for(std::map <int, scanning_port>::iterator i = scanning_ports.begin(); i!= scanning_ports.end() && !(result ^ isscan); ++i){
if(! (*i).second.done ){
sudp.sendto(destname.c_str(), (*i).first, zmsg, UDP_SCAN_ZSIZE, 0);
--- 83,88 ----
sicmp.setsockopt(SOL_SOCKET, SO_RCVBUF, &size, sizeof(size));
! for(repeats = 1; repeats <= UDP_SCAN_REPEATS && next; repeats++){
! for(std::map <int, scanning_port>::iterator i = scanning_ports.begin(); i!= scanning_ports.end() && next; ++i){
if(! (*i).second.done ){
sudp.sendto(destname.c_str(), (*i).first, zmsg, UDP_SCAN_ZSIZE, 0);
***************
*** 102,105 ****
--- 103,107 ----
else{
result = true;
+ next = false;
}
}
***************
*** 121,124 ****
--- 123,127 ----
else{
result = true;
+ next = false;
}
}
***************
*** 126,130 ****
}
iceusleep(50000*repeats);
! }while(recvbytes > 0 && !(result ^ isscan));
}
}
--- 129,133 ----
}
iceusleep(50000*repeats);
! }while(recvbytes > 0 && next);
}
}
|