Index: metrics_library.cc |
diff --git a/metrics_library.cc b/metrics_library.cc |
index 05e63acff5fd32861647adeefd80b450050863b1..f2046a35e50fb170140085507d1204f56d4fe783 100644 |
--- a/metrics_library.cc |
+++ b/metrics_library.cc |
@@ -255,3 +255,17 @@ bool MetricsLibrary::SendUserActionToUMA(const std::string& action) { |
// Send the message. |
return SendMessageToChrome(message_length, message); |
} |
+ |
+bool MetricsLibrary::SendCrashToUMA(const char *crash_kind) { |
+ // Format the message. |
+ char message[kBufferSize]; |
+ int32_t message_length = |
+ FormatChromeMessage(kBufferSize, message, |
+ "crash%c%s", '\0', crash_kind); |
+ |
+ if (message_length < 0) |
+ return false; |
+ |
+ // Send the message. |
+ return SendMessageToChrome(message_length, message); |
+} |