+-- Noteworthy changes in version 1.0.4 (2015-??-??)
+o) Log timestamp format is ISO8601 now
+
+
-- Noteworthy changes in version 1.0.3 (2015-01-28)
o) Fixed bug where HOPM wouldn't try re-connecting to the server in
case the connection got lost.
char data2[513];
char buf_present[25];
va_list arglist;
- time_t present;
- struct tm *tm_present;
+ time_t present = 0;
if (OPT_DEBUG == 0 && logfile == NULL)
return;
time(&present);
- tm_present = gmtime(&present);
- strftime(buf_present, sizeof(buf_present), "%b %d %H:%M:%S %Y", tm_present);
+ strftime(buf_present, sizeof(buf_present), "%FT%H:%M:%S%z", localtime(&present));
va_start(arglist, data);
vsnprintf(data2, 512, data, arglist);
static void
scan_log(OPM_REMOTE_T *remote)
{
- char buf_present[25];
- time_t present;
- struct tm *tm_present;
+ char buf_present[32];
+ time_t present = 0;
struct scan_struct *ss = remote->data;
if (!(OptionsItem->scanlog && scanlogfile))
return;
time(&present);
- tm_present = gmtime(&present);
- strftime(buf_present, sizeof(buf_present), "%b %d %H:%M:%S %Y", tm_present);
+ strftime(buf_present, sizeof(buf_present), "%FT%H:%M:%S%z", localtime(&present));
fprintf(scanlogfile, "[%s] %s:%d (%s) \"%s\"\n", buf_present, remote->ip,
remote->port, scan_gettype(remote->protocol), ss->proof);