Chromium Code Reviews
DescriptionWrap -[BrowserCrApplication nextEventMatchingMask:…] with base::mac::CallWithEHFrame.
nextEventMatchingMask:… is what drives the CFRunLoop on the main thread. While
both -[NSApplication sendEvent:] and all the MessagePumpMac callouts are wrapped
in CallWithEHFrame, other system runloop callouts (like __CFMachPortPerform and
__NSFireDelayedPerform) are not wrapped.
If an exception is raised from within one of those callouts, it will bubble up
to -[NSApplication run], which then swallows the useful stacktrace via
-reportException:/-crashOnException:.
By wrapping nextEventMatchingMask:…, exceptions will generate better crash
stacktraces when raised from system callouts. However, exceptions raised from
libdispatch callouts will not be caught, due to another exception handler in
_dispatch_client_callout. See https://crbug.com/637270#c7 for details.
BUG=637270
R=mark@chromium.org
Committed: https://crrev.com/227b4c54986e2a60c85fcdf880465963f32901db
Cr-Commit-Position: refs/heads/master@{#426366}
Patch Set 1 #Patch Set 2 : NSEventMask problem #
Total comments: 4
Patch Set 3 : __LP64__ #Messages
Total messages: 15 (9 generated)
|