Skip to content

Commit 892cebd

Browse files
committed
logging: Use ISO 8601 time format for logging
Switch locale-aware timestamping for logging / crash handling to %H:%M:%S
1 parent 13e122e commit 892cebd

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

frontend/OBSApp.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,7 @@ string CurrentDateTimeString()
276276
struct tm tstruct;
277277
char buf[80];
278278
tstruct = *localtime(&now);
279-
strftime(buf, sizeof(buf), "%Y-%m-%d, %X", &tstruct);
279+
strftime(buf, sizeof(buf), "%Y-%m-%d, %T", &tstruct);
280280
return buf;
281281
}
282282

libobs/obs-win-crash-handler.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ static inline void write_header(struct exception_handler_data *data)
245245
time_t now = time(0);
246246
struct tm ts;
247247
ts = *localtime(&now);
248-
strftime(date_time, sizeof(date_time), "%Y-%m-%d, %X", &ts);
248+
strftime(date_time, sizeof(date_time), "%Y-%m-%d, %T", &ts);
249249

250250
const char *obs_bitness;
251251
if (sizeof(void *) == 8)

0 commit comments

Comments
 (0)