diff options
Diffstat (limited to 'content/child/runtime_features.cc')
-rw-r--r-- | content/child/runtime_features.cc | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/content/child/runtime_features.cc b/content/child/runtime_features.cc index 1763599..25c6b0e 100644 --- a/content/child/runtime_features.cc +++ b/content/child/runtime_features.cc @@ -209,18 +209,22 @@ void SetRuntimeFeaturesDefaultsAndUpdateFromArgs( // Enable explicitly enabled features, and then disable explicitly disabled // ones. if (command_line.HasSwitch(switches::kEnableBlinkFeatures)) { - std::vector<std::string> enabled_features = base::SplitString( - command_line.GetSwitchValueASCII(switches::kEnableBlinkFeatures), - ",", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL); - for (const std::string& feature : enabled_features) + std::vector<std::string> enabled_features; + base::SplitString( + command_line.GetSwitchValueASCII(switches::kEnableBlinkFeatures), ',', + &enabled_features); + for (const std::string& feature : enabled_features) { WebRuntimeFeatures::enableFeatureFromString(feature, true); + } } if (command_line.HasSwitch(switches::kDisableBlinkFeatures)) { - std::vector<std::string> disabled_features = base::SplitString( - command_line.GetSwitchValueASCII(switches::kDisableBlinkFeatures), - ",", base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL); - for (const std::string& feature : disabled_features) + std::vector<std::string> disabled_features; + base::SplitString( + command_line.GetSwitchValueASCII(switches::kDisableBlinkFeatures), ',', + &disabled_features); + for (const std::string& feature : disabled_features) { WebRuntimeFeatures::enableFeatureFromString(feature, false); + } } } |