mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-01-29 18:49:52 +01:00
Fix crash on shutdown with extensions enabled (see issue #2622).
We don't support the WebRequestAPI yet, so we shouldn't be creating any objects for it. To test: Run `cefclient --enable-network-service` and then close the app.
This commit is contained in:
parent
aa42db6e25
commit
9ce29e8ec5
@ -90,7 +90,6 @@
|
||||
#include "content/public/common/storage_quota_params.h"
|
||||
#include "content/public/common/user_agent.h"
|
||||
#include "content/public/common/web_preferences.h"
|
||||
#include "extensions/browser/api/web_request/web_request_api.h"
|
||||
#include "extensions/browser/extension_message_filter.h"
|
||||
#include "extensions/browser/extension_protocols.h"
|
||||
#include "extensions/browser/extension_registry.h"
|
||||
@ -1176,18 +1175,7 @@ bool CefContentBrowserClient::WillCreateURLLoaderFactory(
|
||||
network::mojom::URLLoaderFactoryRequest* factory_request,
|
||||
network::mojom::TrustedURLLoaderHeaderClientPtrInfo* header_client,
|
||||
bool* bypass_redirect_checks) {
|
||||
if (!extensions::ExtensionsEnabled())
|
||||
return false;
|
||||
|
||||
auto* web_request_api =
|
||||
extensions::BrowserContextKeyedAPIFactory<extensions::WebRequestAPI>::Get(
|
||||
browser_context);
|
||||
bool use_proxy = web_request_api->MaybeProxyURLLoaderFactory(
|
||||
browser_context, frame, render_process_id, is_navigation, is_download,
|
||||
factory_request, header_client);
|
||||
if (bypass_redirect_checks)
|
||||
*bypass_redirect_checks = use_proxy;
|
||||
return use_proxy;
|
||||
return false;
|
||||
}
|
||||
|
||||
void CefContentBrowserClient::OnNetworkServiceCreated(
|
||||
|
Loading…
x
Reference in New Issue
Block a user