mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
chrome: Fix AssertBlockingAllowed() with disk-based Profile creation (see issue #2969)
This commit is contained in:
@@ -6,6 +6,7 @@
|
|||||||
|
|
||||||
#include "libcef/browser/thread_util.h"
|
#include "libcef/browser/thread_util.h"
|
||||||
|
|
||||||
|
#include "base/threading/thread_restrictions.h"
|
||||||
#include "chrome/browser/browser_process.h"
|
#include "chrome/browser/browser_process.h"
|
||||||
#include "chrome/browser/profiles/off_the_record_profile_impl.h"
|
#include "chrome/browser/profiles/off_the_record_profile_impl.h"
|
||||||
#include "chrome/browser/profiles/profile_keep_alive_types.h"
|
#include "chrome/browser/profiles/profile_keep_alive_types.h"
|
||||||
@@ -105,6 +106,9 @@ void ChromeBrowserContext::ProfileCreated(Profile* profile,
|
|||||||
CHECK(!profile);
|
CHECK(!profile);
|
||||||
CHECK(!profile_);
|
CHECK(!profile_);
|
||||||
|
|
||||||
|
// Profile creation may access the filesystem.
|
||||||
|
base::ScopedAllowBlockingForTesting allow_blocking;
|
||||||
|
|
||||||
// Creation of a disk-based profile failed for some reason. Create a
|
// Creation of a disk-based profile failed for some reason. Create a
|
||||||
// new/unique OffTheRecord profile instead.
|
// new/unique OffTheRecord profile instead.
|
||||||
const auto& profile_id = Profile::OTRProfileID::CreateUniqueForCEF();
|
const auto& profile_id = Profile::OTRProfileID::CreateUniqueForCEF();
|
||||||
|
Reference in New Issue
Block a user