Skip to content

Commit

Permalink
Organize and unify timestamp data type in reprostim terms (common and…
Browse files Browse the repository at this point in the history
… ISO 8601 format with precision up to microseconds).
  • Loading branch information
vmdocua committed Mar 17, 2024
1 parent 94b17c8 commit 1885894
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Capture/capturelib/src/CaptureLib.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -413,8 +413,8 @@ namespace reprostim {
std::stringstream ss;
ss << std::put_time(std::localtime(&tsAsTimeT), "%Y-%m-%dT%H:%M:%S");
// put also microseconds up to 6 digits
auto tsAsUs = std::chrono::duration_cast<std::chrono::microseconds>(ts.time_since_epoch()) % 1000000;
ss << '.' << std::setw(6) << std::setfill('0') << tsAsUs.count();
auto nowUs = std::chrono::duration_cast<std::chrono::microseconds>(ts.time_since_epoch()) % 1000000;
ss << '.' << std::setw(6) << std::setfill('0') << nowUs.count();
return ss.str();
}

Expand Down

0 comments on commit 1885894

Please sign in to comment.