Commit 2fb48110 authored by Scott Violet's avatar Scott Violet Committed by Commit Bot

chrome: remove unnecessary conditional

The profile a WebContents is created with should always outlive
the WebContents, so this conditional shouldn't be necessary. This
was likely a work around for this fix:
https://chromium-review.googlesource.com/c/1359827

BUG=none
TEST=none

Change-Id: I37f1117e706e0cf31ef508fdda63dcdb6c2885c3
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2317830Reviewed-by: default avatarCarlos IL <carlosil@chromium.org>
Commit-Queue: Scott Violet <sky@chromium.org>
Cr-Commit-Position: refs/heads/master@{#791681}
parent 26771a9e
......@@ -681,13 +681,8 @@ void HandleSSLErrorWrapper(
SSLErrorHandler::BlockingPageReadyCallback blocking_page_ready_callback) {
Profile* profile =
Profile::FromBrowserContext(web_contents->GetBrowserContext());
// This can happen if GetBrowserContext no longer exists by the time this
// gets called (e.g. the SSL error was in a webview that has since been
// destroyed); if that's the case we don't need to handle the error (and will
// crash if we attempt to).
if (!profile)
return;
// Profile should always outlive a WebContents
DCHECK(profile);
captive_portal::CaptivePortalService* captive_portal_service = nullptr;
......
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