From 0d4879763acdb4c0e602dd0581b2d639b5edef9f Mon Sep 17 00:00:00 2001 From: Marshall Greenblatt Date: Mon, 6 Jan 2020 14:47:18 +0200 Subject: [PATCH] Fix crash when loading a file URL if using CefCookieAccessFilter (fixes issue #2818) --- libcef/browser/net_service/cookie_helper.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/libcef/browser/net_service/cookie_helper.cc b/libcef/browser/net_service/cookie_helper.cc index 75aab5699..1681014fb 100644 --- a/libcef/browser/net_service/cookie_helper.cc +++ b/libcef/browser/net_service/cookie_helper.cc @@ -174,6 +174,7 @@ void SaveCookies(content::BrowserContext* browser_context, CEF_REQUIRE_IOT(); if (request.credentials_mode == network::mojom::CredentialsMode::kOmit || + !head.headers || !head.headers->HasHeader(net_service::kHTTPSetCookieHeaderName)) { // Continue immediately without saving cookies. std::move(done_callback).Run(0, {});