fick put_time, alle meine homies nutzen strftime
This commit is contained in:
parent
a59b5bbace
commit
030f6c2dba
4
Log.cpp
4
Log.cpp
|
@ -171,7 +171,9 @@ std::ostream& defaultEntryMetaTime(std::ostream& os, const Entry& e) {
|
|||
// MinGW doesn't support the ISO8601 formatting characters like "%F" and "%T"
|
||||
// ref: https://sourceforge.net/p/mingw-w64/bugs/793/
|
||||
// Therefore, use a more verbose time string
|
||||
return os << "[" << std::put_time(&tm, "%Y-%m-%d %H:%M:%S") << "]";
|
||||
char buf[24];
|
||||
std::strftime(buf, sizeof(buf), "[%Y-%m-%d %H:%M:%S]", &tm);
|
||||
return os << buf;
|
||||
}
|
||||
|
||||
std::ostream& defaultEntryMetaLevel(std::ostream& os, const Entry& e) {
|
||||
|
|
Loading…
Reference in New Issue