diff --git a/src/logfile.c b/src/logfile.c
index ef3aa97e59b4547fec0aa57992223212bf0071f2..eca8c34758363507872f33ec13b075019c3575a0 100644 (file)
--- a/src/logfile.c
+++ b/src/logfile.c
cdtime_t timestamp_time) {
FILE *fh;
_Bool do_close = 0;
- struct tm timestamp_tm;
char timestamp_str[64];
char level_str[16] = "";
}
if (print_timestamp) {
- time_t tt = CDTIME_T_TO_TIME_T(timestamp_time);
- localtime_r(&tt, ×tamp_tm);
+ struct tm timestamp_tm;
+ localtime_r(&CDTIME_T_TO_TIME_T(timestamp_time), ×tamp_tm);
strftime(timestamp_str, sizeof(timestamp_str), "%Y-%m-%d %H:%M:%S",
×tamp_tm);
plugin_register_notification("logfile", logfile_notification,
/* user_data = */ NULL);
} /* void module_register (void) */
-
-/* vim: set sw=4 ts=4 tw=78 noexpandtab : */