|
@@ -9,6 +9,7 @@
|
|
|
#include <boost/chrono.hpp>
|
|
|
#include <boost/interprocess/ipc/message_queue.hpp>
|
|
|
#include <boost/interprocess/permissions.hpp>
|
|
|
+#include "exLog/log.h"
|
|
|
using namespace boost::interprocess;
|
|
|
|
|
|
#if (defined _WIN32 || defined _WIN64)
|
|
@@ -17,6 +18,7 @@ using namespace boost::interprocess;
|
|
|
|
|
|
void* logProducer = nullptr;
|
|
|
bool g_useMagic = false;
|
|
|
+bool g_loggerInitSuccess = false;
|
|
|
|
|
|
#define NOR_LEN 50
|
|
|
#define MAX_LOG_LEN 4096
|
|
@@ -60,6 +62,17 @@ struct cefclientLog {
|
|
|
#define CEF_GUID "{5ED197CD-9D64-4D10-9839-2A0773B6F5D2}"
|
|
|
|
|
|
|
|
|
+bool InitFileLogger(std::string dbgPath)
|
|
|
+{
|
|
|
+ return g_loggerInitSuccess = logger::init(dbgPath.c_str(), "cefLog");
|
|
|
+}
|
|
|
+
|
|
|
+void DbgToFileLogger(std::string msg)
|
|
|
+{
|
|
|
+ if(g_loggerInitSuccess)
|
|
|
+ logger::showLog(msg);
|
|
|
+}
|
|
|
+
|
|
|
void DbgEx(const char* str, ...)
|
|
|
{
|
|
|
va_list arg;
|