fix: crash when resolving proxy due to network service restart (#42878)

This commit is contained in:
Robo 2024-07-15 17:46:24 +09:00 committed by GitHub
parent bbd7f4a5ad
commit 1e1dc22e16
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 24 additions and 12 deletions

View file

@ -609,8 +609,7 @@ ElectronBrowserContext::GetFileSystemAccessPermissionContext() {
ResolveProxyHelper* ElectronBrowserContext::GetResolveProxyHelper() {
if (!resolve_proxy_helper_) {
resolve_proxy_helper_ = base::MakeRefCounted<ResolveProxyHelper>(
GetDefaultStoragePartition()->GetNetworkContext());
resolve_proxy_helper_ = base::MakeRefCounted<ResolveProxyHelper>(this);
}
return resolve_proxy_helper_.get();
}