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

Unified Diff: android_webview/crash_reporter/aw_microdump_crash_reporter.cc

Issue 2245403002: Don't reuse the minidump descriptor for the crash signal pipe. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: amend comment; default implementation should return an invalid fd Created 4 years, 4 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 | « no previous file | components/crash/content/app/breakpad_linux.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: android_webview/crash_reporter/aw_microdump_crash_reporter.cc
diff --git a/android_webview/crash_reporter/aw_microdump_crash_reporter.cc b/android_webview/crash_reporter/aw_microdump_crash_reporter.cc
index af5c07cfd3e12f63e371344399a0fe74eb6e6d81..23e4bd938187c168e27915cc2bb36c03c22cfc44 100644
--- a/android_webview/crash_reporter/aw_microdump_crash_reporter.cc
+++ b/android_webview/crash_reporter/aw_microdump_crash_reporter.cc
@@ -22,10 +22,10 @@ namespace {
class AwCrashReporterClient : public ::crash_reporter::CrashReporterClient {
public:
- AwCrashReporterClient() : dump_fd_(-1) {}
+ AwCrashReporterClient() : dump_fd_(-1), crash_signal_fd_(-1) {}
// Does not use lock, can only be called immediately after creation.
- void set_crash_signal_fd(int fd) { dump_fd_ = fd; }
+ void set_crash_signal_fd(int fd) { crash_signal_fd_ = fd; }
// crash_reporter::CrashReporterClient implementation.
bool IsRunningUnattended() override { return false; }
@@ -42,6 +42,7 @@ class AwCrashReporterClient : public ::crash_reporter::CrashReporterClient {
bool ShouldEnableBreakpadMicrodumps() override { return true; }
int GetAndroidMinidumpDescriptor() override { return dump_fd_; }
+ int GetAndroidCrashSignalFD() override { return crash_signal_fd_; }
bool DumpWithoutCrashingToFd(int fd) {
DCHECK(dump_fd_ == -1);
@@ -54,6 +55,7 @@ class AwCrashReporterClient : public ::crash_reporter::CrashReporterClient {
private:
int dump_fd_;
+ int crash_signal_fd_;
base::Lock dump_lock_;
DISALLOW_COPY_AND_ASSIGN(AwCrashReporterClient);
};
« no previous file with comments | « no previous file | components/crash/content/app/breakpad_linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698