Index: base/logging_win.h |
diff --git a/base/logging_win.h b/base/logging_win.h |
index 695c7f24b55da65fc9242b3e94a179dc11ccac58..2185309c39b02d9bf42bcf026a52dc244e70c84f 100644 |
--- a/base/logging_win.h |
+++ b/base/logging_win.h |
@@ -10,6 +10,7 @@ |
#include "base/basictypes.h" |
#include "base/win/event_trace_provider.h" |
#include "base/logging.h" |
+#include "base/singleton.h" |
M-A Ruel
2010/12/03 21:06:07
I think you could forward declare the trait instea
Satish
2010/12/04 23:00:40
Done.
|
namespace logging { |
@@ -47,7 +48,7 @@ enum LogMessageTypes { |
// with Event Tracing for Windows. |
class LogEventProvider : public base::win::EtwTraceProvider { |
public: |
- LogEventProvider(); |
+ static LogEventProvider* GetInstance(); |
static bool LogMessage(logging::LogSeverity severity, const char* file, |
int line, size_t message_start, const std::string& str); |
@@ -61,10 +62,13 @@ class LogEventProvider : public base::win::EtwTraceProvider { |
virtual void OnEventsDisabled(); |
private: |
+ LogEventProvider(); |
+ |
// The log severity prior to OnEventsEnabled, |
// restored in OnEventsDisabled. |
logging::LogSeverity old_log_level_; |
+ friend StaticMemorySingletonTraits<LogEventProvider>; |
DISALLOW_COPY_AND_ASSIGN(LogEventProvider); |
}; |