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

Unified Diff: third_party/crashpad/crashpad/util/mach/exception_types.cc

Issue 2555353002: Update Crashpad to 32981a3ee9d7c2769fb27afa038fe2e194cfa329 (Closed)
Patch Set: fix readme Created 4 years 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
Index: third_party/crashpad/crashpad/util/mach/exception_types.cc
diff --git a/third_party/crashpad/crashpad/util/mach/exception_types.cc b/third_party/crashpad/crashpad/util/mach/exception_types.cc
index cef90f9a61aa7b93b213bb72ad6732e91dcab170..09366b57cbab67aaaac1f334709acfad37cd7649 100644
--- a/third_party/crashpad/crashpad/util/mach/exception_types.cc
+++ b/third_party/crashpad/crashpad/util/mach/exception_types.cc
@@ -29,9 +29,9 @@
extern "C" {
-// proc_get_wakemon_params() is present in the Mac OS X 10.9 SDK, but no
-// declaration is provided. This provides a declaration and marks it for weak
-// import if the deployment target is below 10.9.
+// proc_get_wakemon_params() is present in the OS X 10.9 SDK, but no declaration
+// is provided. This provides a declaration and marks it for weak import if the
+// deployment target is below 10.9.
int proc_get_wakemon_params(pid_t pid, int* rate_hz, int* flags)
__OSX_AVAILABLE_STARTING(__MAC_10_9, __IPHONE_7_0);
@@ -76,8 +76,8 @@ ProcGetWakemonParamsType GetProcGetWakemonParams() {
namespace {
// Wraps proc_get_wakemon_params(), calling it if the system provides it. It’s
-// present on Mac OS X 10.9 and later. If it’s not available, sets errno to
-// ENOSYS and returns -1.
+// present on OS X 10.9 and later. If it’s not available, sets errno to ENOSYS
+// and returns -1.
int ProcGetWakemonParams(pid_t pid, int* rate_hz, int* flags) {
#if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_9
// proc_get_wakemon_params() isn’t in the SDK. Look it up dynamically.
@@ -146,17 +146,17 @@ bool IsExceptionNonfatalResource(exception_type_t exception,
// RLIMIT_CPU_USAGE_MONITOR as the second argument and CPUMON_MAKE_FATAL set
// in the flags.
if (MacOSXMinorVersion() >= 10) {
- // In Mac OS X 10.10, the exception code indicates whether the exception
- // is fatal. See 10.10 xnu-2782.1.97/osfmk/kern/thread.c
+ // In OS X 10.10, the exception code indicates whether the exception is
+ // fatal. See 10.10 xnu-2782.1.97/osfmk/kern/thread.c
// THIS_THREAD_IS_CONSUMING_TOO_MUCH_CPU__SENDING_EXC_RESOURCE().
return resource_flavor == FLAVOR_CPU_MONITOR;
}
- // In Mac OS X 10.9, there’s no way to determine whether the exception is
- // fatal. Unlike RESOURCE_TYPE_WAKEUPS below, there’s no way to determine
- // this outside the kernel. proc_rlimit_control()’s RLIMIT_CPU_USAGE_MONITOR
- // is the only interface to modify CPUMON_MAKE_FATAL, but it’s only able to
- // set this bit, not obtain its current value.
+ // In OS X 10.9, there’s no way to determine whether the exception is fatal.
+ // Unlike RESOURCE_TYPE_WAKEUPS below, there’s no way to determine this
+ // outside the kernel. proc_rlimit_control()’s RLIMIT_CPU_USAGE_MONITOR is
+ // the only interface to modify CPUMON_MAKE_FATAL, but it’s only able to set
+ // this bit, not obtain its current value.
//
// Default to assuming that these exceptions are nonfatal. They are nonfatal
// by default and no users of proc_rlimit_control() were found on 10.9.5

Powered by Google App Engine
This is Rietveld 408576698