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

Side by Side Diff: chrome/browser/chrome_browser_main_win.cc

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 #include "chrome/browser/chrome_browser_main_win.h" 5 #include "chrome/browser/chrome_browser_main_win.h"
6 6
7 #include <windows.h> 7 #include <windows.h>
8 #include <shellapi.h> 8 #include <shellapi.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 20 matching lines...) Expand all
31 #include "chrome/browser/profiles/profile_info_cache.h" 31 #include "chrome/browser/profiles/profile_info_cache.h"
32 #include "chrome/browser/profiles/profile_shortcut_manager.h" 32 #include "chrome/browser/profiles/profile_shortcut_manager.h"
33 #include "chrome/browser/shell_integration.h" 33 #include "chrome/browser/shell_integration.h"
34 #include "chrome/browser/ui/simple_message_box.h" 34 #include "chrome/browser/ui/simple_message_box.h"
35 #include "chrome/browser/ui/uninstall_browser_prompt.h" 35 #include "chrome/browser/ui/uninstall_browser_prompt.h"
36 #include "chrome/common/chrome_constants.h" 36 #include "chrome/common/chrome_constants.h"
37 #include "chrome/common/chrome_result_codes.h" 37 #include "chrome/common/chrome_result_codes.h"
38 #include "chrome/common/chrome_switches.h" 38 #include "chrome/common/chrome_switches.h"
39 #include "chrome/common/chrome_version_info.h" 39 #include "chrome/common/chrome_version_info.h"
40 #include "chrome/common/env_vars.h" 40 #include "chrome/common/env_vars.h"
41 #include "chrome/common/terminate_on_heap_corruption_experiment_win.h"
41 #include "chrome/installer/util/browser_distribution.h" 42 #include "chrome/installer/util/browser_distribution.h"
42 #include "chrome/installer/util/helper.h" 43 #include "chrome/installer/util/helper.h"
43 #include "chrome/installer/util/install_util.h" 44 #include "chrome/installer/util/install_util.h"
44 #include "chrome/installer/util/l10n_string_util.h" 45 #include "chrome/installer/util/l10n_string_util.h"
45 #include "chrome/installer/util/shell_util.h" 46 #include "chrome/installer/util/shell_util.h"
46 #include "content/public/browser/browser_thread.h" 47 #include "content/public/browser/browser_thread.h"
47 #include "content/public/common/main_function_params.h" 48 #include "content/public/common/main_function_params.h"
48 #include "grit/app_locale_settings.h" 49 #include "grit/app_locale_settings.h"
49 #include "grit/chromium_strings.h" 50 #include "grit/chromium_strings.h"
50 #include "grit/generated_resources.h" 51 #include "grit/generated_resources.h"
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after
249 250
250 // Set up a task to verify installed modules in the current process. Use a 251 // Set up a task to verify installed modules in the current process. Use a
251 // delay to reduce the impact on startup time. 252 // delay to reduce the impact on startup time.
252 content::BrowserThread::GetMessageLoopProxyForThread( 253 content::BrowserThread::GetMessageLoopProxyForThread(
253 content::BrowserThread::UI)->PostDelayedTask( 254 content::BrowserThread::UI)->PostDelayedTask(
254 FROM_HERE, 255 FROM_HERE,
255 base::Bind(&VerifyInstallation), 256 base::Bind(&VerifyInstallation),
256 base::TimeDelta::FromSeconds(45)); 257 base::TimeDelta::FromSeconds(45));
257 258
258 InitializeChromeElf(); 259 InitializeChromeElf();
260
261 // TODO(erikwright): Remove this and the implementation of the experiment by
262 // September 2014.
263 InitializeDisableTerminateOnHeapCorruptionExperiment();
259 } 264 }
260 265
261 // static 266 // static
262 void ChromeBrowserMainPartsWin::PrepareRestartOnCrashEnviroment( 267 void ChromeBrowserMainPartsWin::PrepareRestartOnCrashEnviroment(
263 const CommandLine& parsed_command_line) { 268 const CommandLine& parsed_command_line) {
264 // Clear this var so child processes don't show the dialog by default. 269 // Clear this var so child processes don't show the dialog by default.
265 scoped_ptr<base::Environment> env(base::Environment::Create()); 270 scoped_ptr<base::Environment> env(base::Environment::Create());
266 env->UnSetVar(env_vars::kShowRestart); 271 env->UnSetVar(env_vars::kShowRestart);
267 272
268 // For non-interactive tests we don't restart on crash. 273 // For non-interactive tests we don't restart on crash.
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after
438 if (resource_id) 443 if (resource_id)
439 return l10n_util::GetStringUTF16(resource_id); 444 return l10n_util::GetStringUTF16(resource_id);
440 return base::string16(); 445 return base::string16();
441 } 446 }
442 447
443 // static 448 // static
444 void ChromeBrowserMainPartsWin::SetupInstallerUtilStrings() { 449 void ChromeBrowserMainPartsWin::SetupInstallerUtilStrings() {
445 CR_DEFINE_STATIC_LOCAL(TranslationDelegate, delegate, ()); 450 CR_DEFINE_STATIC_LOCAL(TranslationDelegate, delegate, ());
446 installer::SetTranslationDelegate(&delegate); 451 installer::SetTranslationDelegate(&delegate);
447 } 452 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698