summaryrefslogtreecommitdiffstats
path: root/content/renderer/renderer_main.cc
diff options
context:
space:
mode:
authorasvitkine@chromium.org <asvitkine@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-07-02 22:24:57 +0000
committerasvitkine@chromium.org <asvitkine@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-07-02 22:24:57 +0000
commitcd36c6e67313d9a1b21f6c5806dfab527778f1e8 (patch)
tree171e1a059a71fe218e45471584e31f0589801103 /content/renderer/renderer_main.cc
parent7c8fd5646f86c3148bef4aaf2518cb08895b5677 (diff)
downloadchromium_src-cd36c6e67313d9a1b21f6c5806dfab527778f1e8.zip
chromium_src-cd36c6e67313d9a1b21f6c5806dfab527778f1e8.tar.gz
chromium_src-cd36c6e67313d9a1b21f6c5806dfab527778f1e8.tar.bz2
Make --force-fieldtrials not activate them in the browser process.
This is to make this testing flag more consistent with what happens with a server-side field trial, so that the field trial doesn't appear in about:version until client code explicitly queries its state via a group() call. Does not change the behaviour of the --force-fieldtrials flag when passes to the renderer process, where it does need to activate the trials so that they show up in crash reports, etc. BUG=255142 TEST=Start a debug build of Chrome with the command line flag --force-fieldtrials=Bat/Man/ and check that it doesn't show up in chrome://version. Review URL: https://chromiumcodereview.appspot.com/17945002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@209795 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/renderer/renderer_main.cc')
-rw-r--r--content/renderer/renderer_main.cc8
1 files changed, 6 insertions, 2 deletions
diff --git a/content/renderer/renderer_main.cc b/content/renderer/renderer_main.cc
index 94a2537..0cfc505 100644
--- a/content/renderer/renderer_main.cc
+++ b/content/renderer/renderer_main.cc
@@ -186,8 +186,12 @@ int RendererMain(const MainFunctionParams& parameters) {
if (parsed_command_line.HasSwitch(switches::kForceFieldTrials)) {
std::string persistent = parsed_command_line.GetSwitchValueASCII(
switches::kForceFieldTrials);
- bool ret = base::FieldTrialList::CreateTrialsFromString(persistent);
- DCHECK(ret);
+ // Field trials are created in an "activated" state to ensure they get
+ // reported in crash reports.
+ bool result = base::FieldTrialList::CreateTrialsFromString(
+ parsed_command_line.GetSwitchValueASCII(switches::kForceFieldTrials),
+ base::FieldTrialList::ACTIVATE_TRIALS);
+ DCHECK(result);
}
#if defined(ENABLE_PLUGINS)