Add option to enable json logging

This commit is contained in:
Patrick Niklaus
2015-03-23 00:28:38 +01:00
parent a372ade7ce
commit f89f4bd20b
2 changed files with 18 additions and 3 deletions
+12 -3
View File
@@ -48,11 +48,20 @@ class Logger
{
static Logger logger;
bool return_logger = true;
#ifdef NDEBUG
return nullptr;
#else
return &logger;
return_logger = false;
#endif
#ifdef ENABLE_JSON_LOGGING
return_logger = true;
#endif
if (return_logger)
{
return &logger;
}
return nullptr;
}
void initialize(const std::string& name)