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

Unified Diff: ios/web/web_state/ui/crw_web_controller.mm

Issue 2165443002: [ios] Reset SSLStatus to default when navigation fails. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: GetLastCommittedItem() can be nil Created 4 years, 5 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/web/web_state/ui/crw_web_controller.mm
diff --git a/ios/web/web_state/ui/crw_web_controller.mm b/ios/web/web_state/ui/crw_web_controller.mm
index 77a3864e74d0b585dec24706f90389c6490a012e..f45749e6e3cd635dcd527f879cc0896cf582089d 100644
--- a/ios/web/web_state/ui/crw_web_controller.mm
+++ b/ios/web/web_state/ui/crw_web_controller.mm
@@ -3436,6 +3436,11 @@ const NSTimeInterval kSnapshotOverlayTransition = 0.5;
if (!inMainFrame && !userInteracted)
return;
+ // Reset SSL status to default.
+ web::NavigationManager* navManager = self.webState->GetNavigationManager();
+ if (navManager->GetLastCommittedItem())
+ navManager->GetLastCommittedItem()->GetSSL() = web::SSLStatus();
+
NSURL* errorURL = [NSURL
URLWithString:[userInfo objectForKey:NSURLErrorFailingURLStringErrorKey]];
const GURL errorGURL = net::GURLWithNSURL(errorURL);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698