log warnings to std::cerr

This commit is contained in:
Patrick von Reth 2015-04-18 12:48:55 +02:00
parent 7002bff4f9
commit 08e58fd325

View File

@ -85,7 +85,9 @@ SnoreLog::~SnoreLog()
Loger::logFile() << m_msg << "\n";
Loger::logFile().flush();
}
if (Loger::debugLvl() >= m_lvl) {
if (m_lvl == SNORE_WARNING) {
std::cerr << m_msg.toLocal8Bit().constData() << std::endl;
} else if (Loger::debugLvl() >= m_lvl) {
std::cout << m_msg.toLocal8Bit().constData() << std::endl;
}
}