From e03a924992a5f62001ae2887456f5aa04dd56738 Mon Sep 17 00:00:00 2001 From: Eike Ziller Date: Mon, 13 Jan 2025 08:46:48 +0100 Subject: [PATCH] Crashpad: Explicitly enable handling if crashpad is enabled This defaults to kUnset, which is interpreted as enabled by vanilla Crashpad. We want to turn that around, so we have more control over which processes are handled by Crashpad. Change-Id: I877acd5b6fa1e222648f031e68be3837422e96d9 Reviewed-by: hjk --- src/app/main.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/app/main.cpp b/src/app/main.cpp index 365887dfc4e..5d2fa201df9 100644 --- a/src/app/main.cpp +++ b/src/app/main.cpp @@ -450,6 +450,11 @@ void startCrashpad(const AppInfo &appInfo, bool crashReportingEnabled) ->set_gather_indirectly_referenced_memory(crashpad::TriState::kEnabled, 0); } + // Explicitly enable Crashpad handling. This is the default in vanilla Crashpad, + // but we use a version that only handles processes that enable it explicitly, + // so we do not handle arbitrary subprocesses + CrashpadInfo::GetCrashpadInfo()->set_crashpad_handler_behavior(crashpad::TriState::kEnabled); + // Optional arguments to pass to the handler std::vector arguments; arguments.push_back("--no-rate-limit");