Chromium Code Reviews| 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 618 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 629 if (recovery_exit_code) { | 629 if (recovery_exit_code) { |
| 630 // Recovery has failed somehow, so we exit. | 630 // Recovery has failed somehow, so we exit. |
| 631 *exit_code = recovery_exit_code; | 631 *exit_code = recovery_exit_code; |
| 632 return true; | 632 return true; |
| 633 } | 633 } |
| 634 } else { // Not running diagnostics or recovery. | 634 } else { // Not running diagnostics or recovery. |
| 635 diagnostics::DiagnosticsController::GetInstance()->RecordRegularStartup(); | 635 diagnostics::DiagnosticsController::GetInstance()->RecordRegularStartup(); |
| 636 } | 636 } |
| 637 #endif | 637 #endif |
| 638 | 638 |
| 639 if (command_line.HasSwitch(switches::kOriginTrialPublicKey)) { | 639 chrome_content_client_.InitializeOriginTrialPolicy(); |
|
jochen (gone - plz use gerrit)
2016/06/20 11:44:56
chrome shouldn't call content's embedder APIs. Why
iclelland
2016/06/20 18:08:40
This was a temporary situation (as a result of ref
iclelland
2016/06/21 03:33:34
I think the only reason I hadn't made InitializeOr
| |
| 640 chrome_content_client_.origin_trial_key_manager() | |
| 641 ->SetPublicKeyFromASCIIString( | |
| 642 command_line.GetSwitchValueASCII(switches::kOriginTrialPublicKey)); | |
| 643 } | |
| 644 | |
| 645 content::SetContentClient(&chrome_content_client_); | 640 content::SetContentClient(&chrome_content_client_); |
| 646 | 641 |
| 647 #if defined (OS_CHROMEOS) | 642 #if defined (OS_CHROMEOS) |
| 648 // The TLS slot used by metrics::LeakDetector needs to be initialized early to | 643 // The TLS slot used by metrics::LeakDetector needs to be initialized early to |
| 649 // ensure that it gets assigned a low slow number. If it gets initialized too | 644 // ensure that it gets assigned a low slow number. If it gets initialized too |
| 650 // late, the glibc TLS system will require a malloc call in order to allocate | 645 // late, the glibc TLS system will require a malloc call in order to allocate |
| 651 // storage for a higher slot number. Normally that's not a problem, but in | 646 // storage for a higher slot number. Normally that's not a problem, but in |
| 652 // LeakDetector it will result in recursive alloc hook function calls. | 647 // LeakDetector it will result in recursive alloc hook function calls. |
| 653 metrics::LeakDetector::InitTLSSlot(); | 648 metrics::LeakDetector::InitTLSSlot(); |
| 654 #endif | 649 #endif |
| (...skipping 388 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1043 case version_info::Channel::CANARY: | 1038 case version_info::Channel::CANARY: |
| 1044 return true; | 1039 return true; |
| 1045 case version_info::Channel::DEV: | 1040 case version_info::Channel::DEV: |
| 1046 case version_info::Channel::BETA: | 1041 case version_info::Channel::BETA: |
| 1047 case version_info::Channel::STABLE: | 1042 case version_info::Channel::STABLE: |
| 1048 default: | 1043 default: |
| 1049 // Don't enable instrumentation. | 1044 // Don't enable instrumentation. |
| 1050 return false; | 1045 return false; |
| 1051 } | 1046 } |
| 1052 } | 1047 } |
| OLD | NEW |