summaryrefslogtreecommitdiff
path: root/src/lib/log.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2015-10-15 12:03:30 +0100
committerCarl Hetherington <cth@carlh.net>2015-10-15 12:03:30 +0100
commitf0da433894308ed72b0dbdd116a30a8d659c33cc (patch)
tree41ed9c78f92f3682276884fa9dca87922e2a34c3 /src/lib/log.cc
parente7811b466eff496db7f63842df2fa4a4410afe14 (diff)
Log to stdout in DCPOMATIC_DEBUG.
Diffstat (limited to 'src/lib/log.cc')
-rw-r--r--src/lib/log.cc9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/lib/log.cc b/src/lib/log.cc
index 0f7a59ff8..d4f469602 100644
--- a/src/lib/log.cc
+++ b/src/lib/log.cc
@@ -32,6 +32,7 @@
#include "i18n.h"
using std::string;
+using std::cout;
using boost::shared_ptr;
Log::Log ()
@@ -69,7 +70,13 @@ Log::log (string message, int type)
return;
}
- do_log (shared_ptr<const LogEntry> (new StringLogEntry (type, message)));
+ shared_ptr<StringLogEntry> e (new StringLogEntry (type, message));
+
+#ifdef DCPOMATIC_DEBUG
+ cout << e->get() << "\n";
+#endif
+
+ do_log (e);
}
void