summaryrefslogtreecommitdiff
path: root/src/debug/Log.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/debug/Log.cpp')
-rw-r--r--src/debug/Log.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/debug/Log.cpp b/src/debug/Log.cpp
index 8b82c852..7547204a 100644
--- a/src/debug/Log.cpp
+++ b/src/debug/Log.cpp
@@ -1,6 +1,7 @@
#include "Log.hpp"
#include "../defines.hpp"
#include "../Compositor.hpp"
+#include "RollingLogFollow.hpp"
#include <fstream>
#include <iostream>
@@ -73,6 +74,9 @@ void Debug::log(LogLevel level, std::string str) {
if (rollingLog.size() > ROLLING_LOG_SIZE)
rollingLog = rollingLog.substr(rollingLog.size() - ROLLING_LOG_SIZE);
+ if (RollingLogFollow::Get().IsRunning())
+ RollingLogFollow::Get().AddLog(str);
+
if (!disableLogs || !**disableLogs) {
// log to a file
std::ofstream ofs;