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

Unified Diff: content/browser/renderer_host/render_process_host_impl.cc

Issue 2365273004: Initial implementation for sharing field trial state (win) (Closed)
Patch Set: add missing include Created 4 years, 2 months 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/render_process_host_impl.cc
diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc
index 0aa3d6020fd4c9d7784408e14a5807d5ea6e0aa0..8627848c6029b6ad83b9d0211a40da0539eba6e7 100644
--- a/content/browser/renderer_host/render_process_host_impl.cc
+++ b/content/browser/renderer_host/render_process_host_impl.cc
@@ -966,7 +966,7 @@ bool RenderProcessHostImpl::Init() {
// at this stage.
child_process_launcher_.reset(new ChildProcessLauncher(
new RendererSandboxedProcessLauncherDelegate(channel_.get()), cmd_line,
- GetID(), this, child_token_,
+ GetID(), this, field_trial_state_.get(), child_token_,
base::Bind(&RenderProcessHostImpl::OnMojoError, id_)));
channel_->Pause();
@@ -1579,7 +1579,7 @@ static void AppendCompositorCommandLineFlags(base::CommandLine* command_line) {
}
void RenderProcessHostImpl::AppendRendererCommandLine(
- base::CommandLine* command_line) const {
+ base::CommandLine* command_line) {
// Pass the process type first, so it shows first in process listings.
command_line->AppendSwitchASCII(switches::kProcessType,
switches::kRendererProcess);
@@ -1618,7 +1618,7 @@ void RenderProcessHostImpl::AppendRendererCommandLine(
void RenderProcessHostImpl::PropagateBrowserCommandLineToRenderer(
const base::CommandLine& browser_cmd,
- base::CommandLine* renderer_cmd) const {
+ base::CommandLine* renderer_cmd) {
// Propagate the following switches to the renderer command line (along
// with any associated values) if present in the browser command line.
static const char* const kSwitchNames[] = {
@@ -1831,7 +1831,8 @@ void RenderProcessHostImpl::PropagateBrowserCommandLineToRenderer(
renderer_cmd->CopySwitchesFrom(browser_cmd, kSwitchNames,
arraysize(kSwitchNames));
- BrowserChildProcessHostImpl::CopyFeatureAndFieldTrialFlags(renderer_cmd);
+ field_trial_state_ =
+ BrowserChildProcessHostImpl::CopyFeatureAndFieldTrialFlags(renderer_cmd);
if (browser_cmd.HasSwitch(switches::kTraceStartup) &&
BrowserMainLoop::GetInstance()->is_tracing_startup_for_duration()) {

Powered by Google App Engine
This is Rietveld 408576698