1
0
mirror of https://github.com/nmap/nmap.git synced 2026-01-04 05:39:01 +00:00

Eddie traceroute localhost fix

This commit is contained in:
fyodor
2007-04-25 21:20:15 +00:00
parent fe09ddaecb
commit 9bc73ed043
2 changed files with 12 additions and 2 deletions

View File

@@ -8,6 +8,10 @@ o Fixed a bug which prevented the NSE scripts directory from appearing
o Fixed a bug in Traceroute's output. It occured when a traced host could
be fully consolidated, but only the first hop number was outputted. [Kris]
o Fixed a Traceroute bug relating to scanning through the localhost
interface on Windows (which previously caused a crash). Thanks to
Alan Jones for the report and Eddie Bell for the fix.
o Updated IANA assignment IP list for random IP (-iR) generation. [Kris]
4.21ALPHA4

View File

@@ -198,8 +198,12 @@ Traceroute::Traceroute (const char *device_name, devtype type) {
fd = -1;
ethsd = NULL;
hops = NULL;
pd = NULL;
total_size = 0;
if(type == devt_loopback)
return;
/* open various socks to send and read from on windows and
* unix */
if ((o.sendpref & PACKET_SEND_ETH) && type == devt_ethernet) {
@@ -305,8 +309,10 @@ Traceroute::~Traceroute () {
delete (it->second);
if (ethsd)
ethsd = NULL;
close (fd);
pcap_close (pd);
if (fd != -1)
close (fd);
if(pd)
pcap_close (pd);
}
/* get an open or closed port from the portlist. Traceroute requires a positive response,