mirror of
https://github.com/nmap/nmap.git
synced 2026-10-20 19:01:56 +00:00
Fix printStatusMessage to show the correct elapsed time after 24
minutes. Part of what printStatusMessage does is display the total elapsed time. The code looked like this: log_write(LOG_STDOUT, "Stats: %d:%02d:%02d elapsed; %d hosts completed (%d up), %d undergoing %s\n", time/60/24, time/60 % 24, time % 60, o.numhosts_scanned - o.numhosts_scanning, o.numhosts_up, o.numhosts_scanning, scantype2str(o.current_scantype)); where time is the number of seconds since the program started. However, this code acts as though each hour has only 24 minutes. That is, after 0:23:59 it would become 1:00:00. This commit changes the 24s to 60s to make it work right.
This commit is contained in:
parent
64b7e255ef
commit
1ea0135dc8
1 changed files with 1 additions and 1 deletions
|
|
@ -1824,7 +1824,7 @@ void printStatusMessage() {
|
|||
|
||||
log_write(LOG_STDOUT,
|
||||
"Stats: %d:%02d:%02d elapsed; %d hosts completed (%d up), %d undergoing %s\n",
|
||||
time/60/24, time/60 % 24, time % 60, o.numhosts_scanned - o.numhosts_scanning,
|
||||
time/60/60, time/60 % 60, time % 60, o.numhosts_scanned - o.numhosts_scanning,
|
||||
o.numhosts_up, o.numhosts_scanning, scantype2str(o.current_scantype));
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue