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

Side by Side Diff: chrome/browser/mac/exception_processor.h

Issue 2543813003: [Mac] Modify the ObjC exception preprocessor to make some exceptions fatal. (Closed)
Patch Set: Address comments 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_MAC_EXCEPTION_PROCESSOR_H_
6 #define CHROME_BROWSER_MAC_EXCEPTION_PROCESSOR_H_
7
8 #include <stddef.h>
9
10 @class NSException;
11
12 namespace chrome {
13
14 // Installs the Objective-C exception preprocessor. This records UMA and crash
15 // keys for NSException objects. The preprocessor will also make fatal any
16 // exception that is not handled.
17 void InstallObjcExceptionPreprocessor();
18
19 // The items below are exposed only for testing.
20 ////////////////////////////////////////////////////////////////////////////////
21
22 // Removes the exception preprocessor if it is installed.
23 void UninstallObjcExceptionPreprocessor();
24
25 // Bin for unknown exceptions.
26 extern const size_t kUnknownNSException;
27
28 // Returns the histogram bin for |exception| if it is one we track
29 // specifically, or |kUnknownNSException| if unknown.
30 size_t BinForException(NSException* exception);
31
32 // Use UMA to track exception occurance.
33 void RecordExceptionWithUma(NSException* exception);
34
35 } // namespace chrome
36
37 #endif // CHROME_BROWSER_MAC_EXCEPTION_PROCESSOR_H_
OLDNEW
« no previous file with comments | « chrome/browser/chrome_browser_application_mac_unittest.mm ('k') | chrome/browser/mac/exception_processor.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698