openbsd-ports/net/nmap/patches/patch-output_cc
giovanni e6fc392521 Update to 6.25
lot of improvements in nse scripting engine and in ipv6 support
Full changelog: http://nmap.org/changelog.html
Help and ok sthen@ and dcoppa@
2012-12-19 17:12:11 +00:00

47 lines
2.1 KiB
Plaintext

$OpenBSD: patch-output_cc,v 1.2 2012/12/19 17:12:11 giovanni Exp $
--- output.cc.orig Thu Nov 29 04:19:52 2012
+++ output.cc Fri Nov 30 12:41:48 2012
@@ -2411,7 +2411,7 @@ void printStatusMessage() {
// Pre-computations
struct timeval tv;
gettimeofday(&tv, NULL);
- int time = (int) (o.TimeSinceStart(&tv));
+ int time = (int) (o.TimeSinceStart((const bpf_timeval*)&tv));
log_write(LOG_STDOUT, "Stats: %d:%02d:%02d elapsed; %d hosts completed (%d up), %d undergoing %s\n",
time / 60 / 60, time / 60 % 60, time % 60, o.numhosts_scanned,
@@ -2431,13 +2431,13 @@ void print_xml_finished_open(time_t timep, const struc
xml_open_start_tag("finished");
xml_attribute("time", "%lu", (unsigned long) timep);
xml_attribute("timestr", "%s", mytime);
- xml_attribute("elapsed", "%.2f", o.TimeSinceStart(tv));
+ xml_attribute("elapsed", "%.2f", o.TimeSinceStart((const bpf_timeval*)&tv));
xml_attribute("summary",
"Nmap done at %s; %d %s (%d %s up) scanned in %.2f seconds",
mytime, o.numhosts_scanned,
(o.numhosts_scanned == 1) ? "IP address" : "IP addresses",
o.numhosts_up, (o.numhosts_up == 1) ? "host" : "hosts",
- o.TimeSinceStart(tv));
+ o.TimeSinceStart((const bpf_timeval*)&tv));
}
void print_xml_hosts() {
@@ -2482,7 +2482,7 @@ void printfinaloutput() {
o.numhosts_scanned,
(o.numhosts_scanned == 1) ? "IP address" : "IP addresses",
o.numhosts_up, (o.numhosts_up == 1) ? "host" : "hosts",
- o.TimeSinceStart(&tv));
+ o.TimeSinceStart((const bpf_timeval*)&tv));
if (o.verbose && o.isr00t && o.RawScan())
log_write(LOG_STDOUT | LOG_SKID, " %s\n",
getFinalPacketStats(statbuf, sizeof(statbuf)));
@@ -2504,7 +2504,7 @@ void printfinaloutput() {
mytime, o.numhosts_scanned,
(o.numhosts_scanned == 1) ? "IP address" : "IP addresses",
o.numhosts_up, (o.numhosts_up == 1) ? "host" : "hosts",
- o.TimeSinceStart(&tv));
+ o.TimeSinceStart((const bpf_timeval*)&tv));
xml_end_tag(); /* nmaprun */
xml_newline();