2020-03-04 01:29:39 +01:00
|
|
|
diff --git content/browser/storage_partition_impl.cc content/browser/storage_partition_impl.cc
|
2023-12-06 21:16:15 +01:00
|
|
|
index 9aad7b5bb5ac8..bb31eb35c9aa4 100644
|
2020-03-04 01:29:39 +01:00
|
|
|
--- content/browser/storage_partition_impl.cc
|
|
|
|
+++ content/browser/storage_partition_impl.cc
|
2023-11-21 20:17:55 +01:00
|
|
|
@@ -543,10 +543,6 @@ class LoginHandlerDelegate {
|
2020-03-04 01:29:39 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
WebContents* web_contents = web_contents_getter_.Run();
|
|
|
|
- if (!web_contents) {
|
2021-06-04 03:34:56 +02:00
|
|
|
- OnAuthCredentials(absl::nullopt);
|
2020-03-04 01:29:39 +01:00
|
|
|
- return;
|
|
|
|
- }
|
|
|
|
|
|
|
|
// WeakPtr is not strictly necessary here due to OnRequestCancelled.
|
|
|
|
creating_login_delegate_ = true;
|
2023-11-21 20:17:55 +01:00
|
|
|
@@ -598,12 +594,6 @@ void OnAuthRequiredContinuation(
|
2020-12-02 23:31:49 +01:00
|
|
|
mojo::PendingRemote<network::mojom::AuthChallengeResponder>
|
|
|
|
auth_challenge_responder,
|
|
|
|
base::RepeatingCallback<WebContents*(void)> web_contents_getter) {
|
|
|
|
- if (!web_contents_getter || !web_contents_getter.Run()) {
|
2020-03-04 01:29:39 +01:00
|
|
|
- mojo::Remote<network::mojom::AuthChallengeResponder>
|
|
|
|
- auth_challenge_responder_remote(std::move(auth_challenge_responder));
|
2021-06-04 03:34:56 +02:00
|
|
|
- auth_challenge_responder_remote->OnAuthCredentials(absl::nullopt);
|
2020-03-04 01:29:39 +01:00
|
|
|
- return;
|
|
|
|
- }
|
2021-09-20 11:06:23 +02:00
|
|
|
new LoginHandlerDelegate(
|
|
|
|
std::move(auth_challenge_responder), std::move(web_contents_getter),
|
2021-11-10 22:57:31 +01:00
|
|
|
auth_info, is_request_for_primary_main_frame, process_id, request_id, url,
|
2023-12-06 21:16:15 +01:00
|
|
|
@@ -3349,8 +3339,12 @@ void StoragePartitionImpl::GetQuotaSettings(
|
2020-03-04 01:29:39 +01:00
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
+ // CEF always returns false for IsOffTheRecord(), so also check the path.
|
|
|
|
+ const bool is_incognito = browser_context_->IsOffTheRecord() ||
|
|
|
|
+ browser_context_->GetPath().empty();
|
2020-06-09 19:48:00 +02:00
|
|
|
+
|
2020-03-04 01:29:39 +01:00
|
|
|
storage::GetNominalDynamicSettings(
|
|
|
|
- GetPath(), browser_context_->IsOffTheRecord(),
|
|
|
|
+ GetPath(), is_incognito,
|
|
|
|
storage::GetDefaultDeviceInfoHelper(), std::move(callback));
|
|
|
|
}
|
|
|
|
|
2023-12-06 21:16:15 +01:00
|
|
|
@@ -3360,9 +3354,12 @@ void StoragePartitionImpl::InitNetworkContext() {
|
2021-10-19 00:17:16 +02:00
|
|
|
cert_verifier::mojom::CertVerifierCreationParamsPtr
|
|
|
|
cert_verifier_creation_params =
|
|
|
|
cert_verifier::mojom::CertVerifierCreationParams::New();
|
|
|
|
- GetContentClient()->browser()->ConfigureNetworkContextParams(
|
|
|
|
+ if (!GetContentClient()->browser()->ConfigureNetworkContextParams(
|
2021-08-20 01:40:49 +02:00
|
|
|
browser_context_, is_in_memory(), relative_partition_path_,
|
2021-10-19 00:17:16 +02:00
|
|
|
- context_params.get(), cert_verifier_creation_params.get());
|
|
|
|
+ context_params.get(), cert_verifier_creation_params.get())) {
|
2020-07-20 19:49:16 +02:00
|
|
|
+ // Don't re-initialize the network context during shutdown.
|
2020-03-04 01:29:39 +01:00
|
|
|
+ return;
|
|
|
|
+ }
|
2021-12-16 23:35:54 +01:00
|
|
|
// Should be initialized with existing per-profile CORS access lists.
|
|
|
|
DCHECK(context_params->cors_origin_access_list.empty())
|
|
|
|
<< "NetworkContextParams::cors_origin_access_list should be populated "
|