Skip to content

Commit

Permalink
cast to time_t
Browse files Browse the repository at this point in the history
  • Loading branch information
odygrd authored Nov 1, 2023
1 parent 3dd2330 commit 6ee78dc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions quill/src/detail/misc/FileUtilities.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ fs::path append_date_time_to_filename(fs::path const& filename, bool with_time,
std::string get_datetime_string(uint64_t timestamp_ns, Timezone timezone, bool with_time)
{
// convert to seconds
time_t time_now = static_cast<uint64_t>(timestamp_ns / 1000000000);
time_t time_now = static_cast<time_t>(timestamp_ns / 1000000000);
tm now_tm;

if (timezone == Timezone::GmtTime)
Expand Down Expand Up @@ -168,4 +168,4 @@ fs::path append_string_to_filename(fs::path const& filename, std::string const&
return ss.str();
}

} // namespace quill::detail
} // namespace quill::detail

0 comments on commit 6ee78dc

Please sign in to comment.