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

Unified Diff: src/platform/crash/crash_dumper.h

Issue 2121012: Simplify libcrash_dumper interface and make window_manager gen crash dumps (Closed) Base URL: ssh://git@chromiumos-git//chromeos
Patch Set: Change crash dumper lib name Created 10 years, 7 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
« no previous file with comments | « src/platform/crash/Makefile ('k') | src/platform/crash/crash_dumper.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/platform/crash/crash_dumper.h
diff --git a/src/platform/crash/crash_dumper.h b/src/platform/crash/crash_dumper.h
index 4dafbeb00f462ac000e1f31f87d95061b6d80018..04e69e4664f061cfe9674987b5f38baeb0db868c 100644
--- a/src/platform/crash/crash_dumper.h
+++ b/src/platform/crash/crash_dumper.h
@@ -5,16 +5,6 @@
#ifndef CRASH_CRASH_DUMPER_H_
#define CRASH_CRASH_DUMPER_H_
-#include <string>
-
-#include "base/scoped_ptr.h"
-
-namespace google_breakpad {
-class ExceptionHandler;
-}
-
-class FilePath;
-
// Class to manage crash handling and dumping. When Enable is called, all
// crashes will be caught and stored to the appropriate crash directory.
// The directory will be:
@@ -22,9 +12,17 @@ class FilePath;
// /var/spool/crash - for all other processes
// The class takes care of creating the directories (even recreating them
// at crash time in case the cryptohome mounting changes from Enable time.
+//
+// For most use cases, there is no need to include or call any functions
+// explicitly in this header file. Crash dumping is enabled just by linking
+// in libcrash_dumper.
class CrashDumper {
public:
+ CrashDumper() {
+ Enable();
+ }
+
~CrashDumper() {
if (IsEnabled()) {
Disable();
« no previous file with comments | « src/platform/crash/Makefile ('k') | src/platform/crash/crash_dumper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698