Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(141)

Unified Diff: chrome/common/crash_keys.cc

Issue 11761030: Create the crash key registration system and register some Mac-specific keys. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: '' Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« base/debug/crash_logging_unittest.cc ('K') | « chrome/common/crash_keys.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/crash_keys.cc
diff --git a/chrome/common/crash_keys.cc b/chrome/common/crash_keys.cc
index 55b0864c40e0fab3b81d8c0a2b9e7f35d07cd458..9290c4bf7f643b4a97fd8e69a4b266c5da020a5d 100644
--- a/chrome/common/crash_keys.cc
+++ b/chrome/common/crash_keys.cc
@@ -6,6 +6,34 @@
namespace crash_keys {
+// TODO(rsesek): This is true on Mac and Linux but not Windows.
+static const size_t kSingleChunkLength = 255;
Scott Hess - ex-Googler 2013/01/10 18:43:54 My max_length comment was that if all of the max_l
Robert Sesek 2013/01/10 19:46:56 Ah, I like it. Done.
Scott Hess - ex-Googler 2013/01/10 20:16:28 Yeah. I think it would be more justified if this
+
+size_t RegisterChromeCrashKeys() {
+ base::debug::CrashKey keys[] = {
+#if defined(OS_MACOSX)
+ { mac::kFirstNSException, 1, kSingleChunkLength },
+ { mac::kFirstNSExceptionTrace, 1, kSingleChunkLength },
+ { mac::kLastNSException, 1, kSingleChunkLength },
+ { mac::kLastNSExceptionTrace, 1, kSingleChunkLength },
+ { mac::kNSException, 1, kSingleChunkLength },
+ { mac::kSendAction, 1, kSingleChunkLength },
+ { mac::kZombie, 1, kSingleChunkLength },
+ { mac::kZombieTrace, 1, kSingleChunkLength },
+ // content/:
+ { "channel_error_bt", 1, kSingleChunkLength },
+ { "remove_route_bt", 1, kSingleChunkLength },
+ { "rwhvm_window", 1, kSingleChunkLength },
+ // media/:
+ { "VideoCaptureDeviceQTKit", 1, kSingleChunkLength },
+#endif
+ };
+
+ return base::debug::InitCrashKeys(keys, arraysize(keys));
+}
+
+// Crash Key Name Constants ////////////////////////////////////////////////////
+
namespace mac {
const char kFirstNSException[] = "firstexception";
« base/debug/crash_logging_unittest.cc ('K') | « chrome/common/crash_keys.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698