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

Side by Side Diff: content/browser/plugin_loader_posix.cc

Issue 8770025: Zygote most of the uses of the utility process on Linux (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Rebased and adjusted comment in use_linux_zygote flag declaration. Created 9 years 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
« no previous file with comments | « content/app/content_main.cc ('k') | content/browser/utility_process_host.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "content/browser/plugin_loader_posix.h" 5 #include "content/browser/plugin_loader_posix.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/message_loop.h" 8 #include "base/message_loop.h"
9 #include "base/message_loop_proxy.h" 9 #include "base/message_loop_proxy.h"
10 #include "base/metrics/histogram.h" 10 #include "base/metrics/histogram.h"
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 // Check if the list is empty or all plugins have already been loaded before 89 // Check if the list is empty or all plugins have already been loaded before
90 // forking. 90 // forking.
91 if (MaybeRunPendingCallbacks()) 91 if (MaybeRunPendingCallbacks())
92 return; 92 return;
93 93
94 if (load_start_time_.is_null()) 94 if (load_start_time_.is_null())
95 load_start_time_ = base::TimeTicks::Now(); 95 load_start_time_ = base::TimeTicks::Now();
96 96
97 process_host_ = new UtilityProcessHost(this, BrowserThread::IO); 97 process_host_ = new UtilityProcessHost(this, BrowserThread::IO);
98 process_host_->set_no_sandbox(true); 98 process_host_->set_no_sandbox(true);
99 process_host_->set_use_linux_zygote(false);
99 #if defined(OS_MACOSX) 100 #if defined(OS_MACOSX)
100 process_host_->set_child_flags(ChildProcessHost::CHILD_ALLOW_HEAP_EXECUTION); 101 process_host_->set_child_flags(ChildProcessHost::CHILD_ALLOW_HEAP_EXECUTION);
101 #endif 102 #endif
102 103
103 process_host_->Send(new UtilityMsg_LoadPlugins(canonical_list_)); 104 process_host_->Send(new UtilityMsg_LoadPlugins(canonical_list_));
104 } 105 }
105 106
106 void PluginLoaderPosix::OnPluginLoaded(uint32 index, 107 void PluginLoaderPosix::OnPluginLoaded(uint32 index,
107 const webkit::WebPluginInfo& plugin) { 108 const webkit::WebPluginInfo& plugin) {
108 if (index != next_load_index_) { 109 if (index != next_load_index_) {
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 171
171 PluginLoaderPosix::PendingCallback::PendingCallback( 172 PluginLoaderPosix::PendingCallback::PendingCallback(
172 scoped_refptr<base::MessageLoopProxy> loop, 173 scoped_refptr<base::MessageLoopProxy> loop,
173 const PluginService::GetPluginsCallback& cb) 174 const PluginService::GetPluginsCallback& cb)
174 : target_loop(loop), 175 : target_loop(loop),
175 callback(cb) { 176 callback(cb) {
176 } 177 }
177 178
178 PluginLoaderPosix::PendingCallback::~PendingCallback() { 179 PluginLoaderPosix::PendingCallback::~PendingCallback() {
179 } 180 }
OLDNEW
« no previous file with comments | « content/app/content_main.cc ('k') | content/browser/utility_process_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698