- fix logger - use template method finally

This commit is contained in:
2026-02-28 06:36:31 +03:00
parent ece1847796
commit 226bbe9b0b
3 changed files with 9 additions and 11 deletions

View File

@@ -372,9 +372,9 @@ void UserAgent::stop()
// Dump statistics here // Dump statistics here
ICELogInfo(<< "Remaining " ICELogInfo(<< "Remaining "
<< Session::InstanceCounter << " session(s), " << Session::InstanceCounter.load() << " session(s), "
<< ResipSession::InstanceCounter << " resip DialogSet(s), " << ResipSession::InstanceCounter.load() << " resip DialogSet(s), "
<< resip::ClientRegistration::InstanceCounter << " ClientRegistration(s)"); << resip::ClientRegistration::InstanceCounter.load() << " ClientRegistration(s)");
mDum->shutdown(this); mDum->shutdown(this);
onDumCanBeDeleted(); onDumCanBeDeleted();

View File

@@ -445,13 +445,6 @@ Logger::operator<<(const uint64_t data)
return *this; return *this;
} }
Logger&
Logger::operator<<(const size_t data)
{
*mStream << data;
return *this;
}
Logger& Logger&
Logger::operator << (const std::string& data) Logger::operator << (const std::string& data)
{ {

View File

@@ -129,9 +129,14 @@ public:
Logger& operator << (const int64_t data); Logger& operator << (const int64_t data);
Logger& operator << (const unsigned int data); Logger& operator << (const unsigned int data);
Logger& operator << (const uint64_t data); Logger& operator << (const uint64_t data);
Logger& operator << (const size_t data);
Logger& operator << (const std::filesystem::path& p); Logger& operator << (const std::filesystem::path& p);
Logger& operator << (const std::chrono::milliseconds t); Logger& operator << (const std::chrono::milliseconds t);
template<typename T>
Logger& operator << (const T data)
{
*mStream << data;
return *this;
}
protected: protected:
LogGuard mGuard; LogGuard mGuard;