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 <stdlib.h> | 5 #include <stdlib.h> |
6 | 6 |
7 #if defined(OS_WIN) | 7 #if defined(OS_WIN) |
8 #include <windows.h> | 8 #include <windows.h> |
9 #endif | 9 #endif |
10 | 10 |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
96 } else { | 96 } else { |
97 LOG(INFO) << "gfx::GLSurface::InitializeOneOff failed"; | 97 LOG(INFO) << "gfx::GLSurface::InitializeOneOff failed"; |
98 gpu_info.gpu_accessible = false; | 98 gpu_info.gpu_accessible = false; |
99 dead_on_arrival = true; | 99 dead_on_arrival = true; |
100 } | 100 } |
101 | 101 |
102 // Warm up the random subsystem, which needs to done pre-sandbox on all | 102 // Warm up the random subsystem, which needs to done pre-sandbox on all |
103 // platforms. | 103 // platforms. |
104 (void) base::RandUint64(); | 104 (void) base::RandUint64(); |
105 | 105 |
106 #if defined(OS_LINUX) | |
107 content::InitializeSandbox(); | |
108 #endif | |
jln (very slow on Chromium)
2012/05/10 03:16:39
I would also leave that as is
Jorge Lucangeli Obes
2012/05/10 03:38:34
Done.
| |
109 | |
110 base::win::ScopedCOMInitializer com_initializer; | 106 base::win::ScopedCOMInitializer com_initializer; |
111 | 107 |
112 #if defined(OS_WIN) | 108 #if defined(OS_WIN) |
113 // Preload this DLL because the sandbox prevents it from loading. | 109 // Preload this DLL because the sandbox prevents it from loading. |
114 LoadLibrary(L"setupapi.dll"); | 110 LoadLibrary(L"setupapi.dll"); |
115 | 111 |
116 sandbox::TargetServices* target_services = | 112 sandbox::TargetServices* target_services = |
117 parameters.sandbox_info->target_services; | 113 parameters.sandbox_info->target_services; |
118 // Initialize H/W video decoding stuff which fails in the sandbox. | 114 // Initialize H/W video decoding stuff which fails in the sandbox. |
119 DXVAVideoDecodeAccelerator::PreSandboxInitialization(); | 115 DXVAVideoDecodeAccelerator::PreSandboxInitialization(); |
(...skipping 29 matching lines...) Expand all Loading... | |
149 child_thread->Init(start_time); | 145 child_thread->Init(start_time); |
150 | 146 |
151 gpu_process.set_main_thread(child_thread); | 147 gpu_process.set_main_thread(child_thread); |
152 | 148 |
153 main_message_loop.Run(); | 149 main_message_loop.Run(); |
154 | 150 |
155 child_thread->StopWatchdog(); | 151 child_thread->StopWatchdog(); |
156 | 152 |
157 return 0; | 153 return 0; |
158 } | 154 } |
OLD | NEW |