src: format_iso8601: Fix invalid millisecond formatting
This commit is contained in:
parent
5bac7f0ca6
commit
75a1ad8bdb
|
@ -719,7 +719,7 @@ std::string format_iso8601(const std::chrono::system_clock::time_point& tp)
|
|||
char buf[128];
|
||||
|
||||
auto nwrite = strftime(buf, sizeof(buf), "%Y-%m-%dT%H:%M:%S", &tms);
|
||||
snprintf(&buf[nwrite], sizeof(buf) - nwrite, ".%ldZ", t.count() % 1000);
|
||||
snprintf(&buf[nwrite], sizeof(buf) - nwrite, ".%03ldZ", t.count() % 1000);
|
||||
|
||||
return buf;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue