mirror of
https://github.com/gabime/spdlog.git
synced 2025-09-29 01:29:35 +08:00
google-build-namespaces
This commit is contained in:
@@ -317,9 +317,9 @@ inline int utc_minutes_offset(const std::tm& tm = details::os::localtime())
|
||||
}
|
||||
};
|
||||
|
||||
long int offset_seconds = helper::calculate_gmt_offset(tm);
|
||||
auto offset_seconds = helper::calculate_gmt_offset(tm);
|
||||
#else
|
||||
long int offset_seconds = tm.tm_gmtoff;
|
||||
auto offset_seconds = tm.tm_gmtoff;
|
||||
#endif
|
||||
|
||||
return static_cast<int>(offset_seconds / 60);
|
||||
|
@@ -34,8 +34,6 @@ public:
|
||||
///////////////////////////////////////////////////////////////////////
|
||||
// name & level pattern appenders
|
||||
///////////////////////////////////////////////////////////////////////
|
||||
namespace
|
||||
{
|
||||
class name_formatter : public flag_formatter
|
||||
{
|
||||
void format(details::log_msg& msg, const std::tm&) override
|
||||
@@ -43,7 +41,6 @@ class name_formatter : public flag_formatter
|
||||
msg.formatted << *msg.logger_name;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
// log level appender
|
||||
class level_formatter : public flag_formatter
|
||||
@@ -344,7 +341,6 @@ private:
|
||||
|
||||
int get_cached_offset(const log_msg& msg, const std::tm& tm_time)
|
||||
{
|
||||
using namespace std::chrono;
|
||||
std::lock_guard<std::mutex> l(_mutex);
|
||||
if (msg.time - _last_update >= cache_refresh)
|
||||
{
|
||||
|
Reference in New Issue
Block a user