Index: remoting/base/logger.cc |
diff --git a/remoting/client/client_logger.cc b/remoting/base/logger.cc |
similarity index 60% |
rename from remoting/client/client_logger.cc |
rename to remoting/base/logger.cc |
index b970697ab838b49a1bbf2d7003187d933a443c6e..f4def7bc9503fc6b51a0e7702c5bbc37aab94fa7 100644 |
--- a/remoting/client/client_logger.cc |
+++ b/remoting/base/logger.cc |
@@ -2,7 +2,7 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-#include "remoting/client/client_logger.h" |
+#include "remoting/base/logger.h" |
#include <stdarg.h> // va_list |
@@ -10,34 +10,38 @@ |
namespace remoting { |
-ClientLogger::ClientLogger() { |
+// Copied from base/logging.cc. |
+const char* const Logger::log_severity_names[logging::LOG_NUM_SEVERITIES] = { |
+ "INFO", "WARNING", "ERROR", "ERROR_REPORT", "FATAL" }; |
+ |
+Logger::Logger() { |
} |
-ClientLogger::~ClientLogger() { |
+Logger::~Logger() { |
} |
-void ClientLogger::Log(logging::LogSeverity severity, const char* format, ...) { |
+void Logger::Log(logging::LogSeverity severity, const char* format, ...) { |
va_list ap; |
va_start(ap, format); |
va_Log(severity, format, ap); |
va_end(ap); |
} |
-void ClientLogger::VLog(int verboselevel, const char* format, ...) { |
+void Logger::VLog(int verboselevel, const char* format, ...) { |
va_list ap; |
va_start(ap, format); |
va_VLog(verboselevel, format, ap); |
va_end(ap); |
} |
-void ClientLogger::va_Log(logging::LogSeverity severity, |
+void Logger::va_Log(logging::LogSeverity severity, |
const char* format, va_list ap) { |
std::string message; |
base::StringAppendV(&message, format, ap); |
logging::LogMessage(__FILE__, __LINE__, severity).stream() << message; |
} |
-void ClientLogger::va_VLog(int verboselevel, const char* format, va_list ap) { |
+void Logger::va_VLog(int verboselevel, const char* format, va_list ap) { |
std::string message; |
base::StringAppendV(&message, format, ap); |
VLOG(verboselevel) << message; |