Index: util/mach/mach_extensions.h |
diff --git a/util/mach/mach_extensions.h b/util/mach/mach_extensions.h |
index 4f2861bf6446e2be186e3c6bc31956e970aa1c3b..a569aa8ca8b0c59d4f049e35a4f20f24fd679615 100644 |
--- a/util/mach/mach_extensions.h |
+++ b/util/mach/mach_extensions.h |
@@ -115,6 +115,20 @@ exception_mask_t ExcMaskAll(); |
//! support is present. |
exception_mask_t ExcMaskValid(); |
+//! \brief Obtains the system’s default Mach exception handler for crash-type |
+//! exceptions. |
+//! |
+//! This is obtained by looking up `"com.apple.ReportCrash"` with the bootstrap |
+//! server. The service name comes from the first launch agent loaded by |
+//! `launchd` with a `MachServices` entry having `ExceptionServer` set. This |
+//! launch agent is normally loaded from |
+//! `/System/Library/LaunchAgents/com.apple.ReportCrash.plist`. |
+//! |
+//! \return On success, a send right to a Mach exception handler corresponding |
+//! to the system’s default crash reporter. On failure, `MACH_PORT_NULL`, |
+//! with a message logged. |
+exception_handler_t SystemCrashReporterHandler(); |
Robert Sesek
2015/10/02 18:30:19
I think this could return a ScopedMachSendRight, s
|
+ |
} // namespace crashpad |
#endif // CRASHPAD_UTIL_MACH_MACH_EXTENSIONS_H_ |