|
|
@ -72,7 +72,7 @@ void Logger::freeInstance() |
|
|
|
void Logger::addMessage(const QString &message, const Log::MsgType &type) |
|
|
|
void Logger::addMessage(const QString &message, const Log::MsgType &type) |
|
|
|
{ |
|
|
|
{ |
|
|
|
QWriteLocker locker(&m_lock); |
|
|
|
QWriteLocker locker(&m_lock); |
|
|
|
const Log::Msg msg = {m_msgCounter++, QDateTime::currentMSecsSinceEpoch(), type, message}; |
|
|
|
const Log::Msg msg = {m_msgCounter++, type, QDateTime::currentMSecsSinceEpoch(), message}; |
|
|
|
m_messages.push_back(msg); |
|
|
|
m_messages.push_back(msg); |
|
|
|
locker.unlock(); |
|
|
|
locker.unlock(); |
|
|
|
|
|
|
|
|
|
|
@ -82,7 +82,7 @@ void Logger::addMessage(const QString &message, const Log::MsgType &type) |
|
|
|
void Logger::addPeer(const QString &ip, const bool blocked, const QString &reason) |
|
|
|
void Logger::addPeer(const QString &ip, const bool blocked, const QString &reason) |
|
|
|
{ |
|
|
|
{ |
|
|
|
QWriteLocker locker(&m_lock); |
|
|
|
QWriteLocker locker(&m_lock); |
|
|
|
const Log::Peer msg = {m_peerCounter++, QDateTime::currentMSecsSinceEpoch(), ip, blocked, reason}; |
|
|
|
const Log::Peer msg = {m_peerCounter++, blocked, QDateTime::currentMSecsSinceEpoch(), ip, reason}; |
|
|
|
m_peers.push_back(msg); |
|
|
|
m_peers.push_back(msg); |
|
|
|
locker.unlock(); |
|
|
|
locker.unlock(); |
|
|
|
|
|
|
|
|
|
|
|