mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Fix crash using CefCookieManager::SetStoragePath (issue #2522)
This commit is contained in:
@@ -6,19 +6,15 @@
|
||||
#define CEF_LIBCEF_BROWSER_COOKIE_STORE_PROXY_H_
|
||||
#pragma once
|
||||
|
||||
#include "include/cef_request_context_handler.h"
|
||||
|
||||
#include "net/cookies/cookie_store.h"
|
||||
|
||||
class CefURLRequestContextImpl;
|
||||
class CefCookieStoreSource;
|
||||
|
||||
// Proxies cookie requests to the CefRequestContextHandler or global cookie
|
||||
// store. Life span is controlled by CefURLRequestContextProxy. Only accessed on
|
||||
// the IO thread. See browser_context.h for an object relationship diagram.
|
||||
// Proxies cookie requests to a CefCookieStoreSource (see comments on the
|
||||
// implementation classes for details). Only accessed on the IO thread.
|
||||
class CefCookieStoreProxy : public net::CookieStore {
|
||||
public:
|
||||
CefCookieStoreProxy(CefURLRequestContextImpl* parent,
|
||||
CefRefPtr<CefRequestContextHandler> handler);
|
||||
explicit CefCookieStoreProxy(std::unique_ptr<CefCookieStoreSource> source);
|
||||
~CefCookieStoreProxy() override;
|
||||
|
||||
// net::CookieStore methods.
|
||||
@@ -52,11 +48,7 @@ class CefCookieStoreProxy : public net::CookieStore {
|
||||
private:
|
||||
net::CookieStore* GetCookieStore();
|
||||
|
||||
// The |parent_| pointer is kept alive by CefURLRequestContextGetterProxy
|
||||
// which has a ref to the owning CefURLRequestContextGetterImpl.
|
||||
CefURLRequestContextImpl* parent_;
|
||||
CefRefPtr<CefRequestContextHandler> handler_;
|
||||
|
||||
std::unique_ptr<CefCookieStoreSource> const source_;
|
||||
std::unique_ptr<net::CookieChangeDispatcher> null_dispatcher_;
|
||||
|
||||
DISALLOW_COPY_AND_ASSIGN(CefCookieStoreProxy);
|
||||
|
Reference in New Issue
Block a user