aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/util/Log.cpp
diff options
context:
space:
mode:
authorLoek Le Blansch <loek@pipeframe.xyz>2024-11-16 21:45:36 +0100
committerLoek Le Blansch <loek@pipeframe.xyz>2024-11-16 21:45:36 +0100
commit73598a9e7f49047d74ca439cb0f300099d8c03bf (patch)
treeef62148ac6769f169670a1e7f7fd8482045ef65f /src/crepe/util/Log.cpp
parentd258fcc8efdb6a968a220c4590a204292a16ad42 (diff)
parent121b64b1cb6cfead5814070c8b0185d3d7308095 (diff)
merge `master` into `loek/audio`
Diffstat (limited to 'src/crepe/util/Log.cpp')
-rw-r--r--src/crepe/util/Log.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/crepe/util/Log.cpp b/src/crepe/util/Log.cpp
index e583734..84d80a8 100644
--- a/src/crepe/util/Log.cpp
+++ b/src/crepe/util/Log.cpp
@@ -1,9 +1,8 @@
-#include <cstdarg>
-#include <cstdio>
-#include <cstdlib>
+#include <iostream>
#include <string>
#include "../api/Config.h"
+
#include "Log.h"
using namespace crepe;
@@ -33,6 +32,6 @@ void Log::log(const Level & level, const string & msg) {
if (!out.ends_with("\n")) out += "\n";
// TODO: also log to file or smth
- fwrite(out.c_str(), 1, out.size(), stdout);
- fflush(stdout);
+ cout.write(out.data(), out.size());
+ cout.flush();
}