Commit 5018f3af authored by Livvie Lin's avatar Livvie Lin Committed by Commit Bot

Re-assign ssl_info later in the code for committed interstitials

There was a bug where the error code and button text were incorrect
on committed interstitials. The cause was that some SSLInfo fields
were being updated later on in the code, so ssl_info shouldn't be
set until after this is done.

Bug: 987407
Change-Id: If82b15e2243ed1865e5b4d604c6aa6cebf7af9ef
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1910845Reviewed-by: default avatarEugene But <eugenebut@chromium.org>
Commit-Queue: Livvie Lin <livvielin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#715929}
parent 56bf9c47
......@@ -1978,7 +1978,6 @@ void ReportOutOfSyncURLInDidStartProvisionalNavigation(
if (web::IsWKWebViewSSLCertError(error) &&
base::FeatureList::IsEnabled(web::features::kSSLCommittedInterstitials)) {
web::GetSSLInfoFromWKWebViewSSLCertError(error, &info);
ssl_info = base::make_optional<net::SSLInfo>(info);
if (info.cert) {
// Retrieve verification results from _certVerificationErrors cache to
// avoid unnecessary recalculations. Verification results are cached for
......@@ -2007,6 +2006,7 @@ void ReportOutOfSyncURLInDidStartProvisionalNavigation(
}
}
}
ssl_info = base::make_optional<net::SSLInfo>(info);
} else if (web::IsWKWebViewSSLCertError(error) &&
!base::FeatureList::IsEnabled(
web::features::kSSLCommittedInterstitials)) {
......
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