Index: chrome/browser/profiles/profile.cc |
diff --git a/chrome/browser/profiles/profile.cc b/chrome/browser/profiles/profile.cc |
index 2867fcfa2bfd5a7d724c2ea0080cd987a98e6eee..5305eb7ee0326b5c82bca58c9d4db1ffb345e843 100644 |
--- a/chrome/browser/profiles/profile.cc |
+++ b/chrome/browser/profiles/profile.cc |
@@ -27,6 +27,7 @@ |
#include "chrome/browser/extensions/extension_special_storage_policy.h" |
#include "chrome/browser/extensions/extension_webrequest_api.h" |
#include "chrome/browser/net/pref_proxy_config_service.h" |
+#include "chrome/browser/prefs/incognito_mode_prefs.h" |
#include "chrome/browser/prefs/pref_service.h" |
#include "chrome/browser/profiles/off_the_record_profile_io_data.h" |
#include "chrome/browser/profiles/profile_dependency_manager.h" |
@@ -238,7 +239,8 @@ class OffTheRecordProfileImpl : public Profile, |
ProfileDependencyManager::GetInstance()->CreateProfileServices(this, false); |
- DCHECK(real_profile->GetPrefs()->GetBoolean(prefs::kIncognitoEnabled)); |
+ DCHECK_NE(IncognitoModePrefs::DISABLED, |
+ IncognitoModePrefs::GetAvailability(real_profile->GetPrefs())); |
// TODO(oshima): Remove the need to eagerly initialize the request context |
// getter. chromeos::OnlineAttempt is illegally trying to access this |