1
0
mirror of https://github.com/EduApps-CDG/OpenDX synced 2024-12-30 09:45:37 +01:00
OpenDX/src/util/log/log.cpp

26 lines
426 B
C++
Raw Normal View History

2017-10-10 23:32:13 +02:00
#include "log.h"
namespace dxvk {
Log::Log(const std::string& filename)
: m_stream(filename, std::ios_base::out | std::ios_base::trunc) {
}
Log::~Log() {
}
void Log::log(const std::string& message) {
std::lock_guard<std::mutex> lock(m_mutex);
std::cerr << message << std::endl;
std::cerr.flush();
m_stream << message << std::endl;
m_stream.flush();
}
}