Commit f4ec95a6 authored by Lily Chen's avatar Lily Chen Committed by Chromium LUCI CQ

Fix reference_wrapper bug in Android WebView cookie feature override

This fixes a bug where a base::Feature ref was implicitly converted to
reference_wrapper incorrectly, such that the feature override worked on
debug builds but not on release builds. This explicitly converts it via
std::cref, which fixes the behavior for release builds.

Bug: 986319
Change-Id: Ic2511f71d83b2c25e4a5cbf2bc8a3f205fec464e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2640921Reviewed-by: default avatarRichard Coles <torne@chromium.org>
Commit-Queue: Lily Chen <chlily@chromium.org>
Cr-Commit-Position: refs/heads/master@{#845317}
parent b2c01993
......@@ -110,7 +110,7 @@ GetSwitchDependentFeatureOverrides(const base::CommandLine& command_line) {
// default.
if (command_line.HasSwitch(switches::kWebViewEnableModernCookieSameSite)) {
feature_overrides.push_back(
std::make_pair(net::features::kSchemefulSameSite,
std::make_pair(std::cref(net::features::kSchemefulSameSite),
base::FeatureList::OVERRIDE_ENABLE_FEATURE));
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment