fixed gcc bugs and warnings

This commit is contained in:
gabime
2014-10-14 04:56:10 +03:00
parent ef330729cb
commit 391bd396ef
5 changed files with 27 additions and 27 deletions

View File

@@ -2,7 +2,6 @@
//
#include <mutex>
#include "c11log/logger.h"
#include "c11log/pattern_formatter.h"
#include "c11log/sinks/async_sink.h"
#include "c11log/sinks/file_sinks.h"
#include "c11log/sinks/stdout_sinks.h"
@@ -21,7 +20,7 @@ int main(int argc, char* argv[])
const unsigned int howmany = argc <= 1 ? 500000 : atoi(argv[1]);
std::string pattern = "%Y:%m:%d %H:%M:%S.%e [%n:%l] %t";
auto formatter1 = std::unique_ptr<formatter>(new pattern_formatter(pattern));
auto formatter1 = std::unique_ptr<formatter>(new details::pattern_formatter(pattern));
logger cout_logger("bench", std::make_shared<sinks::stderr_sink_mt>() , std::move(formatter1));
cout_logger.info() << "Hello logger";
@@ -30,7 +29,7 @@ int main(int argc, char* argv[])
auto rotating = std::make_shared<sinks::rotating_file_sink_mt>("myrotating", "txt", 1024 * 1024 * 5, 5, 100);
auto formatter2 = std::unique_ptr<formatter>(new pattern_formatter(pattern));
auto formatter2 = std::unique_ptr<formatter>(new details::pattern_formatter(pattern));
logger my_logger("my_logger", rotating, std::move(formatter2));
auto start = system_clock::now();