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

Side by Side Diff: content/public/app/content_main.h

Issue 402723002: Experimentally disable termination on heap corrruption in order to measure the contribution of this… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Update comment date. Created 6 years, 4 months 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_PUBLIC_APP_CONTENT_MAIN_H_ 5 #ifndef CONTENT_PUBLIC_APP_CONTENT_MAIN_H_
6 #define CONTENT_PUBLIC_APP_CONTENT_MAIN_H_ 6 #define CONTENT_PUBLIC_APP_CONTENT_MAIN_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include "base/callback_forward.h" 10 #include "base/callback_forward.h"
11 #include "build/build_config.h" 11 #include "build/build_config.h"
12 #include "content/common/content_export.h" 12 #include "content/common/content_export.h"
13 13
14 #if defined(OS_WIN) 14 #if defined(OS_WIN)
15 #include <windows.h> 15 #include <windows.h>
16 #endif 16 #endif
17 17
18 namespace sandbox { 18 namespace sandbox {
19 struct SandboxInterfaceInfo; 19 struct SandboxInterfaceInfo;
20 } 20 }
21 21
22 namespace content { 22 namespace content {
23 class ContentMainDelegate; 23 class ContentMainDelegate;
24 24
25 struct ContentMainParams { 25 struct ContentMainParams {
26 explicit ContentMainParams(ContentMainDelegate* delegate) 26 explicit ContentMainParams(ContentMainDelegate* delegate)
27 : delegate(delegate), 27 : delegate(delegate),
28 enable_termination_on_heap_corruption(true),
28 #if defined(OS_WIN) 29 #if defined(OS_WIN)
29 instance(NULL), 30 instance(NULL),
30 sandbox_info(NULL), 31 sandbox_info(NULL),
31 #elif !defined(OS_ANDROID) 32 #elif !defined(OS_ANDROID)
32 argc(0), 33 argc(0),
33 argv(NULL), 34 argv(NULL),
34 #endif 35 #endif
35 ui_task(NULL) { 36 ui_task(NULL) {
36 } 37 }
37 38
38 ContentMainDelegate* delegate; 39 ContentMainDelegate* delegate;
39 40
41 bool enable_termination_on_heap_corruption;
42
40 #if defined(OS_WIN) 43 #if defined(OS_WIN)
41 HINSTANCE instance; 44 HINSTANCE instance;
42 45
43 // |sandbox_info| should be initialized using InitializeSandboxInfo from 46 // |sandbox_info| should be initialized using InitializeSandboxInfo from
44 // content_main_win.h 47 // content_main_win.h
45 sandbox::SandboxInterfaceInfo* sandbox_info; 48 sandbox::SandboxInterfaceInfo* sandbox_info;
46 #elif !defined(OS_ANDROID) 49 #elif !defined(OS_ANDROID)
47 int argc; 50 int argc;
48 const char** argv; 51 const char** argv;
49 #endif 52 #endif
(...skipping 14 matching lines...) Expand all
64 // ContentMain should be called from the embedder's main() function to do the 67 // ContentMain should be called from the embedder's main() function to do the
65 // initial setup for every process. The embedder has a chance to customize 68 // initial setup for every process. The embedder has a chance to customize
66 // startup using the ContentMainDelegate interface. The embedder can also pass 69 // startup using the ContentMainDelegate interface. The embedder can also pass
67 // in NULL for |delegate| if they don't want to override default startup. 70 // in NULL for |delegate| if they don't want to override default startup.
68 CONTENT_EXPORT int ContentMain(const ContentMainParams& params); 71 CONTENT_EXPORT int ContentMain(const ContentMainParams& params);
69 #endif 72 #endif
70 73
71 } // namespace content 74 } // namespace content
72 75
73 #endif // CONTENT_PUBLIC_APP_CONTENT_MAIN_H_ 76 #endif // CONTENT_PUBLIC_APP_CONTENT_MAIN_H_
OLDNEW
« content/app/content_main_runner.cc ('K') | « content/app/content_main_runner.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698