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 <stddef.h> | 5 #include <stddef.h> |
6 #include <utility> | 6 #include <utility> |
7 | 7 |
8 #include "base/base_switches.h" | 8 #include "base/base_switches.h" |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/debug/debugger.h" | 10 #include "base/debug/debugger.h" |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
69 static void HandleRendererErrorTestParameters( | 69 static void HandleRendererErrorTestParameters( |
70 const base::CommandLine& command_line) { | 70 const base::CommandLine& command_line) { |
71 if (command_line.HasSwitch(switches::kWaitForDebugger)) | 71 if (command_line.HasSwitch(switches::kWaitForDebugger)) |
72 base::debug::WaitForDebugger(60, true); | 72 base::debug::WaitForDebugger(60, true); |
73 | 73 |
74 if (command_line.HasSwitch(switches::kRendererStartupDialog)) | 74 if (command_line.HasSwitch(switches::kRendererStartupDialog)) |
75 ChildProcess::WaitForDebugger("Renderer"); | 75 ChildProcess::WaitForDebugger("Renderer"); |
76 } | 76 } |
77 | 77 |
78 #if defined(USE_OZONE) | 78 #if defined(USE_OZONE) |
79 base::LazyInstance<std::unique_ptr<ui::ClientNativePixmapFactory>> | 79 base::LazyInstance<std::unique_ptr<ui::ClientNativePixmapFactory>>:: |
80 g_pixmap_factory = LAZY_INSTANCE_INITIALIZER; | 80 DestructorAtExit g_pixmap_factory = LAZY_INSTANCE_INITIALIZER; |
81 #endif | 81 #endif |
82 | 82 |
83 } // namespace | 83 } // namespace |
84 | 84 |
85 // mainline routine for running as the Renderer process | 85 // mainline routine for running as the Renderer process |
86 int RendererMain(const MainFunctionParams& parameters) { | 86 int RendererMain(const MainFunctionParams& parameters) { |
87 // Don't use the TRACE_EVENT0 macro because the tracing infrastructure doesn't | 87 // Don't use the TRACE_EVENT0 macro because the tracing infrastructure doesn't |
88 // expect synchronous events around the main loop of a thread. | 88 // expect synchronous events around the main loop of a thread. |
89 TRACE_EVENT_ASYNC_BEGIN0("startup", "RendererMain", 0); | 89 TRACE_EVENT_ASYNC_BEGIN0("startup", "RendererMain", 0); |
90 | 90 |
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
206 // ignore shutdown-only leaks. | 206 // ignore shutdown-only leaks. |
207 __lsan_do_leak_check(); | 207 __lsan_do_leak_check(); |
208 #endif | 208 #endif |
209 } | 209 } |
210 platform.PlatformUninitialize(); | 210 platform.PlatformUninitialize(); |
211 TRACE_EVENT_ASYNC_END0("startup", "RendererMain", 0); | 211 TRACE_EVENT_ASYNC_END0("startup", "RendererMain", 0); |
212 return 0; | 212 return 0; |
213 } | 213 } |
214 | 214 |
215 } // namespace content | 215 } // namespace content |
OLD | NEW |