Index: base/logging.h |
=================================================================== |
--- base/logging.h (revision 34497) |
+++ base/logging.h (working copy) |
@@ -765,6 +765,17 @@ |
// after this call. |
void CloseLogFile(); |
+// Async signal safe logging mechanism. |
+void RawLog(int level, const char* message); |
+ |
+#define RAW_LOG(level, message) logging::RawLog(logging::LOG_ ## level, message) |
+ |
+#define RAW_CHECK(condition) \ |
+ do { \ |
+ if (!(condition)) \ |
+ logging::RawLog(logging::LOG_FATAL, "Check failed: " #condition "\n"); \ |
+ } while (0) |
+ |
} // namespace logging |
// These functions are provided as a convenience for logging, which is where we |