1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-06 04:31:29 +00:00

Use ISO 8601 timezone, avoid encoding problems

This commit is contained in:
dmiller
2025-05-08 17:40:53 +00:00
parent c04ad609a9
commit b05b0b04ec

View File

@@ -1551,7 +1551,7 @@ void apply_delayed_options() {
o.reason = true;
// ISO 8601 date/time -- http://www.cl.cam.ac.uk/~mgk25/iso-time.html
if (strftime(tbuf, sizeof(tbuf), "%Y-%m-%d %H:%M %Z", &local_time) <= 0)
if (strftime(tbuf, sizeof(tbuf), "%Y-%m-%d %H:%M %z", &local_time) <= 0)
fatal("Unable to properly format time");
log_write(LOG_STDOUT | LOG_SKID, "Starting %s %s ( %s ) at %s\n", NMAP_NAME, NMAP_VERSION, NMAP_URL, tbuf);
if (o.verbose) {