OLD | NEW |
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/app/chrome_main_delegate.h" | 5 #include "chrome/app/chrome_main_delegate.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/base_paths.h" | 10 #include "base/base_paths.h" |
(...skipping 472 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
483 } | 483 } |
484 #endif | 484 #endif |
485 | 485 |
486 #if defined(OS_MACOSX) | 486 #if defined(OS_MACOSX) |
487 // Give the browser process a longer treadmill, since crashes | 487 // Give the browser process a longer treadmill, since crashes |
488 // there have more impact. | 488 // there have more impact. |
489 const bool is_browser = !command_line.HasSwitch(switches::kProcessType); | 489 const bool is_browser = !command_line.HasSwitch(switches::kProcessType); |
490 ObjcEvilDoers::ZombieEnable(true, is_browser ? 10000 : 1000); | 490 ObjcEvilDoers::ZombieEnable(true, is_browser ? 10000 : 1000); |
491 | 491 |
492 SetUpBundleOverrides(); | 492 SetUpBundleOverrides(); |
493 | 493 chrome::common::mac::EnableCFBundleBlocker(); |
494 // Only enable the CFBundleBlocker in the browser. In child processes, | |
495 // the sandbox will block access to loadable bundle locations. | |
496 if (is_browser) | |
497 chrome::common::mac::EnableCFBundleBlocker(); | |
498 #endif | 494 #endif |
499 | 495 |
500 Profiling::ProcessStarted(); | 496 Profiling::ProcessStarted(); |
501 | 497 |
502 base::trace_event::TraceLog::GetInstance()->SetArgumentFilterPredicate( | 498 base::trace_event::TraceLog::GetInstance()->SetArgumentFilterPredicate( |
503 base::Bind(&IsTraceEventArgsWhitelisted)); | 499 base::Bind(&IsTraceEventArgsWhitelisted)); |
504 | 500 |
505 #if defined(OS_WIN) | 501 #if defined(OS_WIN) |
506 v8_breakpad_support::SetUp(); | 502 v8_breakpad_support::SetUp(); |
507 #endif | 503 #endif |
(...skipping 534 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1042 case version_info::Channel::CANARY: | 1038 case version_info::Channel::CANARY: |
1043 return true; | 1039 return true; |
1044 case version_info::Channel::DEV: | 1040 case version_info::Channel::DEV: |
1045 case version_info::Channel::BETA: | 1041 case version_info::Channel::BETA: |
1046 case version_info::Channel::STABLE: | 1042 case version_info::Channel::STABLE: |
1047 default: | 1043 default: |
1048 // Don't enable instrumentation. | 1044 // Don't enable instrumentation. |
1049 return false; | 1045 return false; |
1050 } | 1046 } |
1051 } | 1047 } |
OLD | NEW |