Add time to log prefix

This commit is contained in:
2023-01-12 20:29:34 +01:00
parent f96dc46ea7
commit 2d250621c8
4 changed files with 27 additions and 8 deletions

@ -408,9 +408,9 @@ const char *http_get_status_color(status_code_t status_code) {
}
}
char *http_format_date(time_t time, char *buf, size_t size) {
char *http_format_date(time_t ts, char *buf, size_t size) {
struct tm time_info;
strftime(buf, size, "%a, %d %b %Y %H:%M:%S GMT", gmtime_r(&time, &time_info));
strftime(buf, size, "%a, %d %b %Y %H:%M:%S GMT", gmtime_r(&ts, &time_info));
return buf;
}